diff --git a/misc/Windows.xml b/hosts/gerg-desktop/Windows.xml
similarity index 99%
rename from misc/Windows.xml
rename to hosts/gerg-desktop/Windows.xml
index bc7b2f6..a995ac1 100644
--- a/misc/Windows.xml
+++ b/hosts/gerg-desktop/Windows.xml
@@ -29,6 +29,7 @@
/var/lib/libvirt/qemu/nvram/Windows_VARS.fd
+
diff --git a/hosts/gerg-desktop/default.nix b/hosts/gerg-desktop/default.nix
index 9aca767..abd82c6 100644
--- a/hosts/gerg-desktop/default.nix
+++ b/hosts/gerg-desktop/default.nix
@@ -56,6 +56,7 @@
deadnix
statix
alejandra
+ nix-index
;
inherit (nvim-flake.packages.${pkgs.system}) neovim;
};
diff --git a/hosts/gerg-desktop/vfio.nix b/hosts/gerg-desktop/vfio.nix
index 9c43208..53bab33 100644
--- a/hosts/gerg-desktop/vfio.nix
+++ b/hosts/gerg-desktop/vfio.nix
@@ -1,8 +1,4 @@
-{
- self,
- pipewire_fix,
- ...
-}: {
+{pipewire_fix, ...}: {
pkgs,
lib,
config,
@@ -108,6 +104,7 @@ in {
environment = {
systemPackages = [
pkgs.virt-manager
+ pkgs.dmidecode
];
shellAliases = {
vm-start = "virsh start Windows";
@@ -162,6 +159,6 @@ in {
in [
"L /etc/Xorg/active.conf - - - - /etc/Xorg/2_mon.conf"
"L+ /var/lib/libvirt/hooks/qemu - - - - ${qemuHook}"
- "L+ /var/lib/libvirt/qemu/Windows.xml - - - - ${self}/misc/Windows.xml"
+ "L+ /var/lib/libvirt/qemu/Windows.xml - - - - ${./Windows.xml}"
];
}
diff --git a/modules/boot/misc.nix b/modules/boot/misc.nix
index 72bb1c2..c93a11f 100644
--- a/modules/boot/misc.nix
+++ b/modules/boot/misc.nix
@@ -31,4 +31,12 @@
timeout = 0;
};
};
+ systemd.services.efibootmgr = {
+ serviceConfig.Type = "oneshot";
+ path = [pkgs.efibootmgr];
+ wantedBy = ["default.target"];
+ script = ''
+ efibootmgr -t 0
+ '';
+ };
}
diff --git a/modules/direnv.nix b/modules/direnv.nix
index a6b86a2..45cff97 100644
--- a/modules/direnv.nix
+++ b/modules/direnv.nix
@@ -17,7 +17,7 @@ _: {pkgs, ...}: {
fi
'';
bash.interactiveShellInit = ''
- if [ $- == *i* ] && ! printenv PATH | grep -qc '/nix/store' && [ -z "$IN_NIX_SHELL" ] ; then
+ if [[ $- == *i* ]] && ! printenv PATH | grep -qc '/nix/store' && [ -z "$IN_NIX_SHELL" ] ; then
eval "$(direnv hook bash)"
fi
'';