refactoe: moce common modules into their own file

This commit is contained in:
Mohammad Rafiq 2025-04-15 09:48:47 +08:00
parent 52ec0abb0c
commit 1561628255
No known key found for this signature in database
2 changed files with 20 additions and 16 deletions

View file

@ -19,25 +19,13 @@
;
};
inherit (inputs.nixpkgs) lib;
commonModules = [
./configs/boot.nix
./configs/nix-config.nix
./configs/security.nix
./configs/users.nix
./configs/networking.nix
./configs/shell.nix
./configs/programs/stylix.nix
];
graphicalModules = [
./configs/graphical.nix
];
in
inputs.nixpkgs.lib.nixosSystem {
specialArgs = args;
modules =
commonModules
++ lib.optionals (type == "graphical") graphicalModules
++ [ ./hosts/${hostname}.nix ];
modules = [
./hosts/common.nix
./hosts/${hostname}.nix
];
};
};
in