Revert refactoring of flake.nix
Apparently refactoring home-manager in the way that I did causes it to crash at switch-time. I have no idea why, but it's gone now.
This commit is contained in:
parent
39a45b3ec5
commit
32c4116c66
39
flake.nix
39
flake.nix
|
@ -17,29 +17,38 @@ outputs = { self,
|
|||
username = "kiana";
|
||||
moduleArgs = inputs // { inherit system username; };
|
||||
lib = nixpkgs.lib;
|
||||
|
||||
modulesFor = system:
|
||||
[
|
||||
{ _module.args = moduleArgs; }
|
||||
./common/config
|
||||
./${system}/config
|
||||
home-manager.nixosModules.home-manager
|
||||
{ home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
users.${username} = import ./${system}/home-manager;
|
||||
extraSpecialArgs = moduleArgs;
|
||||
}; }
|
||||
];
|
||||
in {
|
||||
nixosConfigurations = {
|
||||
"kiana-desktop" = lib.makeOverridable lib.nixosSystem {
|
||||
inherit system;
|
||||
modules = modulesFor "desktop";
|
||||
modules = [
|
||||
{ _module.args = moduleArgs; }
|
||||
./common/config
|
||||
./desktop/config
|
||||
home-manager.nixosModules.home-manager
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.users.${username} = import ./desktop/home-manager;
|
||||
home-manager.extraSpecialArgs = moduleArgs;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
"kiana-laptop" = lib.makeOverridable lib.nixosSystem {
|
||||
inherit system;
|
||||
modules = modulesFor "laptop";
|
||||
modules = [
|
||||
{ _module.args = moduleArgs; }
|
||||
./common/config
|
||||
./laptop/config
|
||||
home-manager.nixosModules.home-manager
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.users.${username} = import ./laptop/home-manager;
|
||||
home-manager.extraSpecialArgs = moduleArgs;
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue