moved common out of systems

This commit is contained in:
2024-10-25 16:47:36 -04:00
parent 84ad676d17
commit f706463500
26 changed files with 19 additions and 19 deletions

28
common/global/nix.nix Normal file
View File

@@ -0,0 +1,28 @@
{
inputs,
lib,
...
}: let
flakeInputs = lib.filterAttrs (_: lib.isType "flake") inputs;
in {
nix = {
settings = {
trusted-users = [
"root"
"@wheel"
];
auto-optimise-store = lib.mkDefault true;
experimental-features = [
"nix-command"
"flakes"
"ca-derivations"
];
warn-dirty = false;
flake-registry = ""; # disable global flake registries
};
# Add each flake input as a registry and nix_path
registry = lib.mapAttrs (_: flake: {inherit flake;}) flakeInputs;
nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
};
}