1
0
Fork 0
mirror of https://git.sr.ht/~neverness/ultima synced 2024-12-28 10:13:54 +00:00
ultima/libx/builder.nix
2024-12-03 23:20:37 +09:00

29 lines
911 B
Nix

{ self, inputs, hostName, userName, flakeDir, dev, ... }: {
flake = let
pkgs = inputs.nixpkgs.legacyPackages.x86_64-linux;
sec = import ./secrets.nix;
args = rec { # IMPORTS LET_IN FROM HOSTS TO ALL SYSTEM
# DIRECTORIES
homeDir = "${flakeDir}/modules/home";
nixosDir = "${flakeDir}/modules/nixos";
# OTHER
True = { enable = true; };
False = { enable = false; };
# SYSINFO
stateVersion = "24.05"; # IDK
platform = "x86_64-linux";
inherit self inputs hostName userName flakeDir sec dev;
};
in with inputs; {
nixosConfigurations.${hostName} = nixpkgs.lib.nixosSystem {
modules = [ ../${hostName}/host ];
specialArgs = args;
};
homeConfigurations.${userName} = home-manager.lib.homeManagerConfiguration {
modules = [ ../${hostName}/home ];
extraSpecialArgs = args;
inherit pkgs;
};
};
}