Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to pin a version without touch package.json #1033

Closed
keidarcy opened this issue Sep 28, 2021 · 1 comment
Closed

How to pin a version without touch package.json #1033

keidarcy opened this issue Sep 28, 2021 · 1 comment

Comments

@keidarcy
Copy link

My team use different tool to manage node version.
I like volta!
How to use a specific version without add "volta": {} to package.json?
Currently, I pin and delete volta part from package.json.

and something like below live in root package.json

  "engines": {
    "node": "12 || 14"
  }
@charlespierce
Copy link
Contributor

Hi @keidarcy! Unfortunately, we don't currently support any other method for pinning the Node version. There's an open issue (that needs some design work to be implementable) tracking the idea of using a separate file to pin the versions: #282

Note that deleting the volta entry from package.json will make Volta use the global defaults (as the package doesn't have any Volta configuration). The only thing that volta pin does (other than cache the requested version locally) is to write that entry, so removing it is effectively undoing volta pin.

As for engines, we actually looked early on at using it, and decided against it, for reasons outlined in this comment: #742 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants