Add option to explicitly choose .nvmrc
or engines.node
#37
Labels
enhancement
New feature or request
.nvmrc
or engines.node
#37
Guidelines
Which problem is this feature request solving?
Currently, the
local
option works as:which, based on testing, in practice first looks for
.nvmrc
and uses that (even ifpackage.json#engines.node
is present) and then looks atpackage.json#engines.node
to choose a Node.js version.In library projects I use both of these, but for different purposes.
package.json#engines.node
is there to tell users of the library which versions of Node.js the library promises to work in..nvmrc
is used to specify the version of Node.js that should be used during development (to make sure all development dependencies work).With
nve local
I can't choose which one I want to use (plus it's not clear which one will be used). But I would like to use something likenve local
to avoid repeating what's in (in my particular case)package.json#engines.node
.Describe the solution you'd like
Either a flag or new subcommand to be able to explicitly select the local source to use for the Node.js version.
Some ideas:
I'd personally deprecate
nve local
since it's ambiguous, but that decision up to the maintainers of the project 🙂Pull request (optional)
The text was updated successfully, but these errors were encountered: