Merge pull request #191 from koenpunt/patch-1

Add exit code, fix #190
master
Tim Caswell 2013-01-21 08:51:14 -08:00
commit 87a76af398
1 changed files with 1 additions and 1 deletions

2
nvm.sh
View File

@ -351,7 +351,7 @@ nvm()
VERSION=`nvm_version $2`
if [ ! -d $NVM_DIR/$VERSION ]; then
echo "$VERSION version is not installed yet"
return;
exit 1
fi
if [[ $PATH == *$NVM_DIR/*/bin* ]]; then
PATH=${PATH%$NVM_DIR/*/bin*}$NVM_DIR/$VERSION/bin${PATH#*$NVM_DIR/*/bin}