Add nvm_validate_implicit_alias

This commit is contained in:
Jordan Harband
2014-09-28 22:36:02 -07:00
parent f0471acbf5
commit fcdd1ef431
2 changed files with 26 additions and 0 deletions

7
nvm.sh
View File

@@ -368,6 +368,13 @@ nvm_print_versions() {
done
}
nvm_validate_implicit_alias() {
if [ "_$1" != "_stable" ] && [ "_$1" != "_unstable" ]; then
echo "Only implicit aliases 'stable' and 'unstable' are supported." >&2
return 1
fi
}
nvm() {
if [ $# -lt 1 ]; then
nvm help