Use $() instead of backticks; add quotes
parent
4f081ce4be
commit
51f6109f8d
4
nvm.sh
4
nvm.sh
|
@ -161,7 +161,7 @@ nvm_version() {
|
||||||
return $?
|
return $?
|
||||||
fi
|
fi
|
||||||
|
|
||||||
VERSION=`nvm_ls $PATTERN | tail -n1`
|
VERSION="$(nvm_ls "$PATTERN" | tail -n1)"
|
||||||
echo "$VERSION"
|
echo "$VERSION"
|
||||||
|
|
||||||
if [ "$VERSION" = 'N/A' ]; then
|
if [ "$VERSION" = 'N/A' ]; then
|
||||||
|
@ -173,7 +173,7 @@ nvm_remote_version() {
|
||||||
local PATTERN
|
local PATTERN
|
||||||
PATTERN=$1
|
PATTERN=$1
|
||||||
local VERSION
|
local VERSION
|
||||||
VERSION=`nvm_ls_remote $PATTERN | tail -n1`
|
VERSION="$(nvm_ls_remote "$PATTERN" | tail -n1)"
|
||||||
echo "$VERSION"
|
echo "$VERSION"
|
||||||
|
|
||||||
if [ "$VERSION" = 'N/A' ]; then
|
if [ "$VERSION" = 'N/A' ]; then
|
||||||
|
|
Loading…
Reference in New Issue