nix registry

This commit is contained in:
Chris Dombroski 2024-07-09 21:14:07 -04:00
parent fa6361b698
commit f04a392d14

View file

@ -1,20 +1,15 @@
{ lib, inputs, config, ... }: { { ... }: {
programs.git.enable = true; programs.git.enable = true;
programs.nh = { programs.nh = {
enable = true; enable = true;
clean.enable = true; clean.enable = true;
clean.extraArgs = "--keep-since 7d"; clean.extraArgs = "--keep-since 7d";
}; };
nix = let flakeInputs = lib.filterAttrs (_: lib.isType "flake") inputs; nix = {
in {
settings = { settings = {
experimental-features = [ "nix-command" "flakes" ]; experimental-features = [ "nix-command" "flakes" ];
flake-registry = "";
nix-path = config.nix.nixPath;
}; };
optimise.automatic = true; optimise.automatic = true;
registry = lib.mapAttrs (_: flake: { inherit flake; }) flakeInputs;
nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
}; };
system.autoUpgrade = { system.autoUpgrade = {
enable = true; enable = true;