From e87155faa2a415ecd5e8999318eeba3438ecfd22 Mon Sep 17 00:00:00 2001 From: Gerg-L Date: Sun, 6 Aug 2023 00:18:14 -0400 Subject: [PATCH] added comments --- modules/nix.nix | 51 +++++++++++++++++++++++++++---------------------- 1 file changed, 28 insertions(+), 23 deletions(-) diff --git a/modules/nix.nix b/modules/nix.nix index 2c0b798..db05989 100644 --- a/modules/nix.nix +++ b/modules/nix.nix @@ -13,34 +13,39 @@ in { nix.nixPath = lib.mapAttrsToList (x: _: "${x}=flake:${x}") flakes; nix.registry = lib.mapAttrs (_: flake: {inherit flake;}) flakes; # - # Ignore global registry + # Use nix directly from master # - nix.settings.flake-registry = builtins.toFile "empty-flake-registry.json" ''{"flakes":[],"version":2}''; + nix.package = inputs.nix.packages.${pkgs.system}.default; # # Other nix settings # - nix = { - package = inputs.nix.packages.${pkgs.system}.default; - settings = { - experimental-features = [ - "nix-command" - "flakes" - "repl-flake" - ]; - auto-optimise-store = true; - warn-dirty = false; - #use for testing - #allow-import-from-derivation = false; - trusted-users = [ - "root" - "@wheel" - ]; - allowed-users = []; - use-xdg-base-directories = true; - }; - }; + nix.settings = { + # + # Ignore global registry + # + flake-registry = builtins.toFile "empty-flake-registry.json" ''{"flakes":[],"version":2}''; - #fix for use-xdg-base-directories + experimental-features = [ + "nix-command" + "flakes" + "repl-flake" + ]; + auto-optimise-store = true; + warn-dirty = false; + # + # Use for testing + # + #allow-import-from-derivation = false; + trusted-users = [ + "root" + "@wheel" + ]; + allowed-users = []; + use-xdg-base-directories = true; + }; + # + # Fix for use-xdg-base-directories https://github.com/NixOS/nixpkgs/pull/241518 + # environment.profiles = [ "\${XDG_STATE_HOME:-$HOME/.local/state}/nix/profile" ];