mirror of
https://github.com/NixOS/nix
synced 2025-07-07 06:01:48 +02:00
nix-shell: In #! mode, pass the last argument
"i < argc - 1" should be "i < argc".
This commit is contained in:
parent
ae1e4dfad2
commit
c287e797a8
3 changed files with 14 additions and 16 deletions
|
@ -17,5 +17,5 @@ output=$(NIX_PATH=nixpkgs=shell.nix nix-shell --pure -p foo bar --run 'echo "$(f
|
|||
sed -e "s|@ENV_PROG@|$(type -p env)|" shell.shebang.sh > $TEST_ROOT/shell.shebang.sh
|
||||
chmod a+rx $TEST_ROOT/shell.shebang.sh
|
||||
|
||||
output=$($TEST_ROOT/shell.shebang.sh)
|
||||
[ "$output" = "foo bar" ]
|
||||
output=$($TEST_ROOT/shell.shebang.sh abc def)
|
||||
[ "$output" = "foo bar abc def" ]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue