You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
nvm use --install 10.4.0 without having installed 10.4.0 prior to invocation
What happened?
N/A: version "10.4.0 -> N/A" is not yet installed.
You need to run "nvm install 10.4.0" to install it before using it.
What did you expect to happen?
nvm should have automatically installed 10.4.0 if it wasn't already installed.
It would be great if use, run & exec provided options for automatically installing the targeted node version if it's not already installed. I'd expect the option to be --install/-i. It would also be nice if a --silent/-s option were supported for silent installation. That way, a user could issue the command nvm run -is 10.4.0 blah.js and nvm would silently install 10.4.0 if it wasn't there then run the command. Running nvm run -is blah.js would silently install & use the node version according to .nvmrc.
The text was updated successfully, but these errors were encountered:
nvm use --install isn't a thing; nvm install already does "install if needed + use".
Supporting --silent on nvm install seems somewhat reasonable, but i'm not excited about silently installing a node version that doesn't get cleaned up later.
@ljharb I don't see the big deal WRT clean up. I have many nvm-managed node versions.
However, if you wanted to, you could make the default behavior to be to remove the installed version after execution, and let users pass a flag to opt out of automatic cleanup with a --no-remove option or something.
The point of my request is really just to reduce the number of commands that have to be run. I just want to nvm run blah.js and it should Just Work鈩笍 without me having to install the targeted Node version or not in a separate step.
Operating system and version:
macOS 10.15.4 (19E287)
nvm debug
output:nvm ls
output:How did you install
nvm
?install script in readme
What steps did you perform?
nvm use --install 10.4.0
without having installed10.4.0
prior to invocationWhat happened?
What did you expect to happen?
nvm
should have automatically installed10.4.0
if it wasn't already installed.It would be great if
use
,run
&exec
provided options for automatically installing the targetednode
version if it's not already installed. I'd expect the option to be--install
/-i
. It would also be nice if a--silent
/-s
option were supported for silent installation. That way, a user could issue the commandnvm run -is 10.4.0 blah.js
andnvm
would silently install10.4.0
if it wasn't there then run the command. Runningnvm run -is blah.js
would silently install & use thenode
version according to.nvmrc
.The text was updated successfully, but these errors were encountered: