From 5e0baa153e62f8a66462622474e5cd0ee4206b22 Mon Sep 17 00:00:00 2001 From: Profpatsch Date: Sun, 8 Dec 2019 13:40:38 +0100 Subject: treewide: use `runCommandLocal` where applicable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `runCommandLocal` was added to nixpkgs in https://github.com/NixOS/nixpkgs/pull/74642 to speed up trivial `runCommand` derivations by always building them locally. We have a few places where that’s good to use. --- tests/sandbox.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/sandbox.nix b/tests/sandbox.nix index 0a860793..66187b23 100644 --- a/tests/sandbox.nix +++ b/tests/sandbox.nix @@ -19,7 +19,7 @@ environment.systemPackages = let mkNestedLinksTo = drv: let - mkLink = name: to: pkgs.runCommand name { inherit to; } '' + mkLink = name: to: pkgs.runCommandLocal name { inherit to; } '' ln -s "$to" "$out" ''; in mkLink "nested-1" (mkLink "nested-2" (mkLink "nested-3" drv)); @@ -50,7 +50,7 @@ # symlinks. lfile="$(< ${mkNestedLinksTo (pkgs.writeText "target" "file")})" test "$lfile" = file - ldir="$(< ${mkNestedLinksTo (pkgs.runCommand "target" {} '' + ldir="$(< ${mkNestedLinksTo (pkgs.runCommandLocal "target" {} '' mkdir -p "$out" echo dir > "$out/canary" '')}/canary)" -- cgit 1.4.1