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

Add pins for Volta #529

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Add pins for Volta #529

wants to merge 1 commit into from

Conversation

fredvd
Copy link
Sponsor Member

@fredvd fredvd commented Mar 13, 2023

Add pins for people using Volta for automatic node/yarn/npm tooling pins & installation/shims.

@petschki
Copy link
Member

what's volta?

@fredvd
Copy link
Sponsor Member Author

fredvd commented Mar 22, 2023

google for 'volta node' ;-)

https://volta.sh/

An IMHO much more convenient and less bloated alternative for nvm.

@jensens
Copy link
Sponsor Member

jensens commented Mar 22, 2023

Volto, Volta, 🤪

@petschki
Copy link
Member

My first thought: this is a typo 🫣

@mauritsvanrees
Copy link
Sponsor Member

Interesting!

Trying it out, starting on master:

$ node --version; yarn --version
v18.14.2
1.22.5
$ git checkout volta_pins 
Switched to branch 'volta_pins'
Your branch is up to date with 'origin/volta_pins'.
$ node --version; yarn --version
v16.19.1
1.22.19

If you don't have those versions yet, Volta will automatically download them.

Nice! I am in favour.

Would be nice for mockup as well, where I always have to check if I need node 14, 16 or 18, and I don't think it is documented. Might be only a problem for the branch used in Plone 5.2 though.

@fredvd
Copy link
Sponsor Member Author

fredvd commented Apr 22, 2023

What I like about Volta is that it has the same functionality as nvm where it manages and downloads separate installs of node/npm/yarn versions. But it also has out of the box automatic activation in a proeject dir. With nvm you need to follow extra instructions to add stuff to your bashrc/profile and nvm is subjectively slower for me. I think it activates on 'cd'-ing in to a directory and uses shell commands.

The Volta shims are binaries and work almost instantly. And if you don't (want to) use Volta, the pins in the package.json are ignored.

Copy link
Member

@petschki petschki left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I always make nvm use 18 ... would do it for volta too.

@@ -37,5 +37,9 @@
"repository": {
"type": "git",
"url": "https://github.com/plone/mockup.git"
},
"volta": {
"node": "16.19.1",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"node": "16.19.1",
"node": "18.17.0",

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

Successfully merging this pull request may close these issues.

4 participants