mirror of
https://github.com/nvm-sh/nvm.git
synced 2025-10-30 00:45:49 +08:00
@@ -17,6 +17,9 @@ echo $(nvm_source "git") | grep "nvm.git$" > /dev/null || die "nvm_source withou
|
||||
# nvm_source with script parameter returns the location of nvm.sh
|
||||
echo $(nvm_source "script") | grep "nvm.sh$" > /dev/null || die "nvm_source \"script\" should return the location of nvm.sh"
|
||||
|
||||
# nvm_source with script-nvm-exec parameter returns the location of nvm-exec
|
||||
echo $(nvm_source "script-nvm-exec") | grep "nvm-exec$" > /dev/null || die "nvm_source \"script-nvm-exec\" should return the location of nvm.sh"
|
||||
|
||||
# nvm_source with any other parameter errors out and exits
|
||||
nvm_source "anything" 2> /dev/null && die "nvm_source with invalid parameter should exit"
|
||||
out=$(nvm_source "anything" 2>&1 >/dev/null) || : #Saving the process here
|
||||
|
||||
Reference in New Issue
Block a user