mirror of
https://github.com/nvm-sh/nvm.git
synced 2025-08-20 04:23:43 +00:00
Merge d2e1836fcd2314e56a8cfa414842853424926e7a into da2720a4292d02746a6b7fdc680c7e163c347355
This commit is contained in:
commit
a4c84c2104
10
nvm.sh
10
nvm.sh
@ -700,10 +700,12 @@ nvm_ensure_version_installed() {
|
||||
nvm_err "N/A: version \"${PREFIXED_VERSION:-$PROVIDED_VERSION}\" is not yet installed."
|
||||
fi
|
||||
nvm_err ""
|
||||
if [ "${IS_VERSION_FROM_NVMRC}" != '1' ]; then
|
||||
nvm_err "You need to run \`nvm install ${PROVIDED_VERSION}\` to install and use it."
|
||||
else
|
||||
nvm_err 'You need to run `nvm install` to install and use the node version specified in `.nvmrc`.'
|
||||
if [ "${PROVIDED_VERSION}" = 'lts' ]; then
|
||||
nvm_err "You need to run \`nvm install --lts\` to install and \`nvm use --lts\` to use it."
|
||||
elif [ "${IS_VERSION_FROM_NVMRC}" != '1' ]; then
|
||||
nvm_err "You need to run \`nvm install ${PROVIDED_VERSION}\` to install and use it."
|
||||
else
|
||||
nvm_err 'You need to run `nvm install` to install and use the node version specified in `.nvmrc`.'
|
||||
fi
|
||||
return 1
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user