mirror of
https://github.com/nvm-sh/nvm.git
synced 2025-05-10 22:31:51 +00:00
Use $() instead of backticks; add quotes
This commit is contained in:
parent
4f081ce4be
commit
51f6109f8d
4
nvm.sh
4
nvm.sh
@ -161,7 +161,7 @@ nvm_version() {
|
||||
return $?
|
||||
fi
|
||||
|
||||
VERSION=`nvm_ls $PATTERN | tail -n1`
|
||||
VERSION="$(nvm_ls "$PATTERN" | tail -n1)"
|
||||
echo "$VERSION"
|
||||
|
||||
if [ "$VERSION" = 'N/A' ]; then
|
||||
@ -173,7 +173,7 @@ nvm_remote_version() {
|
||||
local PATTERN
|
||||
PATTERN=$1
|
||||
local VERSION
|
||||
VERSION=`nvm_ls_remote $PATTERN | tail -n1`
|
||||
VERSION="$(nvm_ls_remote "$PATTERN" | tail -n1)"
|
||||
echo "$VERSION"
|
||||
|
||||
if [ "$VERSION" = 'N/A' ]; then
|
||||
|
Loading…
Reference in New Issue
Block a user