treewide: use nativeBuildInputs with runCommand instead of inlining

This commit is contained in:
Sandro Jäckel 2022-12-18 23:35:29 +01:00
parent 76672661b9
commit 26f704b545
No known key found for this signature in database
GPG key ID: 3AF5A43A3EECC2E5
6 changed files with 46 additions and 33 deletions

View file

@ -77,10 +77,11 @@ let
pkgsLibPath = filter (pkgs.path + "/pkgs/pkgs-lib");
nixosPath = filter (pkgs.path + "/nixos");
modules = map (p: ''"${removePrefix "${modulesPath}/" (toString p)}"'') docModules.lazy;
nativeBuildInputs = with pkgs; [ nix ];
} ''
export NIX_STORE_DIR=$TMPDIR/store
export NIX_STATE_DIR=$TMPDIR/state
${pkgs.buildPackages.nix}/bin/nix-instantiate \
nix-instantiate \
--show-trace \
--eval --json --strict \
--argstr libPath "$libPath" \