diff --git a/modules/nix/nix-darwin.nix b/modules/nix/nix-darwin.nix index 677acbe5..a22e3e03 100644 --- a/modules/nix/nix-darwin.nix +++ b/modules/nix/nix-darwin.nix @@ -5,6 +5,7 @@ let inherit (config.system) profile; inherit (config.environment) systemPath; nixPath = lib.optionalString config.nix.enable (lib.concatStringsSep ":" config.nix.nixPath); + nixPackage = if config.nix.enable then config.nix.package else null; }; darwin-uninstaller = pkgs.callPackage ../../pkgs/darwin-uninstaller { }; diff --git a/pkgs/nix-tools/default.nix b/pkgs/nix-tools/default.nix index 8d6b89b7..a5414cbd 100644 --- a/pkgs/nix-tools/default.nix +++ b/pkgs/nix-tools/default.nix @@ -21,6 +21,7 @@ "/usr/sbin" "/sbin" ] +, nixPackage ? null , # This should be kept in sync with the default `nix.nixPath`. nixPath ? lib.concatStringsSep ":" [ "darwin-config=/etc/nix-darwin/configuration.nix" @@ -29,7 +30,7 @@ }: let - extraPath = lib.makeBinPath [ coreutils jq git ]; + extraPath = lib.makeBinPath [ coreutils jq git nixPackage ]; writeProgram = name: env: src: substituteAll ({