fix: better isWSL handling

This commit is contained in:
2025-01-25 00:44:22 +00:00
parent 7d09ff1adf
commit 4ae878baf9

View File

@@ -24,7 +24,6 @@
} }
{ {
name = "tux"; name = "tux";
isWSL = false;
} }
]; ];
in in
@@ -40,16 +39,20 @@
}; };
}; };
system = "x86_64-linux"; system = "x86_64-linux";
modules = [ modules =
./hosts/${host.name}/configuration.nix [
home-manager.nixosModules.home-manager ./hosts/${host.name}/configuration.nix
{ home-manager.nixosModules.home-manager
nix.settings.experimental-features = [ {
"nix-command" nix.settings.experimental-features = [
"flakes" "nix-command"
]; "flakes"
} ];
] ++ (if host.isWSL then [ nixos-wsl.nixosModules.default ] else [ ]); }
]
++ (
if builtins.hasAttr "isWSL" host && host.isWSL then [ nixos-wsl.nixosModules.default ] else [ ]
);
}; };
}) hosts }) hosts
); );