added darwinConfigurations to homeConfigurations outputs
This commit is contained in:
parent
5f21fd43ff
commit
2583888615
28
flake.nix
28
flake.nix
|
@ -75,9 +75,21 @@
|
||||||
} @ inputs: let
|
} @ inputs: let
|
||||||
util = import ./util {inherit inputs;};
|
util = import ./util {inherit inputs;};
|
||||||
forEachPkgs = util.forEachPkgs;
|
forEachPkgs = util.forEachPkgs;
|
||||||
|
|
||||||
mkNixosSystem = util.mkNixosSystem;
|
mkNixosSystem = util.mkNixosSystem;
|
||||||
mkDarwinSystem = util.mkDarwinSystem;
|
mkDarwinSystem = util.mkDarwinSystem;
|
||||||
mkHome = util.mkHome;
|
mkHome = util.mkHome;
|
||||||
|
|
||||||
|
systemsHomes = nixpkgs.lib.attrsets.mergeAttrsList (
|
||||||
|
nixpkgs.lib.attrsets.mapAttrsToList (hostname: system: (
|
||||||
|
nixpkgs.lib.attrsets.mapAttrs' (user: _: {
|
||||||
|
name = "${user}@${hostname}";
|
||||||
|
value = mkHome user hostname system.pkgs.hostPlatform.system system.config;
|
||||||
|
})
|
||||||
|
system.config.home-manager.users
|
||||||
|
))
|
||||||
|
(inputs.self.nixosConfigurations // inputs.self.darwinConfigurations)
|
||||||
|
);
|
||||||
in {
|
in {
|
||||||
formatter = forEachPkgs (pkgs: pkgs.alejandra);
|
formatter = forEachPkgs (pkgs: pkgs.alejandra);
|
||||||
|
|
||||||
|
@ -111,15 +123,11 @@
|
||||||
hesperium = mkDarwinSystem "hesperium";
|
hesperium = mkDarwinSystem "hesperium";
|
||||||
};
|
};
|
||||||
|
|
||||||
homeConfigurations = nixpkgs.lib.attrsets.mergeAttrsList (
|
homeConfigurations =
|
||||||
nixpkgs.lib.attrsets.mapAttrsToList (hostname: system: (
|
systemsHomes
|
||||||
nixpkgs.lib.attrsets.mapAttrs' (user: _: {
|
// {
|
||||||
name = "${user}@${hostname}";
|
# stand alone configurations here:
|
||||||
value = mkHome user hostname system.pkgs.hostPlatform.system system.config;
|
# name = mkHome "name"
|
||||||
})
|
};
|
||||||
system.config.home-manager.users
|
|
||||||
))
|
|
||||||
self.nixosConfigurations
|
|
||||||
);
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue