Browse Source

fix to proper echo of nvm which. Checkin test which had been left out

master
Daniel Bretoi 10 years ago
parent
commit
a1c0c34088
  1. 2
      nvm.sh
  2. 6
      test/fast/Listing paths/Running "nvm which foo" should return a nonzero exit code when not found

2
nvm.sh

@ -968,7 +968,7 @@ nvm() {
if [ "_$VERSION" = '_system' ]; then
if nvm_has_system_node >/dev/null 2>&1; then
echo $(dirname `which node`)
echo $(nvm use system && echo dirname $(which node))
return
else
echo "System version of node not found." >&2

6
test/fast/Listing paths/Running "nvm which foo" should return a nonzero exit code when not found

@ -0,0 +1,6 @@
#!/bin/sh
. ../../../nvm.sh
nvm which nonexistent_version
[ "$?" = "1" ]
Loading…
Cancel
Save