From a4c9b2595e6e22250e4e744a35fff3c7f9cd85d9 Mon Sep 17 00:00:00 2001 From: Samuel Dionne-Riel Date: Mon, 9 Apr 2018 09:36:54 -0400 Subject: [PATCH] Hardcodes `nix-shell` instead of `/usr/bin/env nix-shell`... ... in the ruby shebang test. --- tests/nix-shell.sh | 2 +- tests/shell.shebang.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/nix-shell.sh b/tests/nix-shell.sh index 7f14b6c31..d25c456ce 100644 --- a/tests/nix-shell.sh +++ b/tests/nix-shell.sh @@ -43,7 +43,7 @@ output=$($TEST_ROOT/shell.shebang.sh abc def) # Test nix-shell shebang mode for ruby # This uses a fake interpreter that returns the arguments passed # This, in turn, verifies the `rc` script is valid and the `load()` script (given using `-e`) is as expected. -sed -e "s|@ENV_PROG@|$(type -p env)|" shell.shebang.rb > $TEST_ROOT/shell.shebang.rb +sed -e "s|@SHELL_PROG@|$(type -p nix-shell)|" shell.shebang.rb > $TEST_ROOT/shell.shebang.rb chmod a+rx $TEST_ROOT/shell.shebang.rb output=$($TEST_ROOT/shell.shebang.rb abc ruby) diff --git a/tests/shell.shebang.rb b/tests/shell.shebang.rb index ea3953ae2..ea67eb09c 100644 --- a/tests/shell.shebang.rb +++ b/tests/shell.shebang.rb @@ -1,4 +1,4 @@ -#! @ENV_PROG@ nix-shell +#! @SHELL_PROG@ #! ruby #! nix-shell -I nixpkgs=shell.nix --no-substitute #! nix-shell --pure -p ruby -i ruby