Merged Host/Home Opt into SysOpt
All checks were successful
Nix Build / build-nixos (push) Successful in 5m27s

This commit is contained in:
soraefir
2024-04-14 07:57:07 +02:00
parent 0a02d67b7e
commit 972cb47e3f
65 changed files with 331 additions and 338 deletions

View File

@ -1,25 +1,35 @@
{ inputs, ... }: {
generate = { type, system, host }:
({
let
nameValuePair = name: value: { inherit name value; };
syscfg = import ./systems/${host}/cfg.nix;
in ({
"nixos" = inputs.nixpkgs.lib.nixosSystem {
system = system;
modules = [
inputs.sops-nix.nixosModules.sops
./modules/shared/syscfg
./modules/shared/sops
./modules/nixos
syscfg
./systems/${host}
inputs.home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.extraSpecialArgs = { inherit inputs; };
home-manager.users.sora = {
imports = [
./modules/home
inputs.nix-colors.homeManagerModule
inputs.hyprland.homeManagerModules.default
./systems/${host}/home.nix
];
};
home-manager.users = builtins.listToAttrs (map (userConfig:
nameValuePair userConfig.username {
imports = [
inputs.nix-colors.homeManagerModule
inputs.hyprland.homeManagerModules.default
./modules/shared/syscfg
./modules/shared/colors
./modules/home
syscfg
{ usercfg = userConfig; }
];
}) syscfg.syscfg.users);
}
];
};