-
Notifications
You must be signed in to change notification settings - Fork 211
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 upgrade / update command #42
Comments
Interesting suggestion. It might be tricky to get all the details right. Some things to think about:
Also, there is another suggestion to add a command to update NVS itself, so the command names should be chosen carefully to avoid confusion. |
I'd need to look at how it currently works
I meant to somehow track whether a specific version was installed by version name or by version label / tag to upgrade only the ones installed by tag. In other words,
I would think so, based on the previous item.
Only if it was linked to a version label / tag, like
Operating on default ("node") remote is fine. Alternatively other remotes except "node" should behave similar to Also maybe |
I don't think I like the idea of having behavior conditional on whether a number or label was used when adding a version. Any of the following commands will get you the latest LTS Boron release (as of now):
Even if you use |
Yes, it makes sense. However I wanted also to have an option to have certain versions sticky / non-upgradable. This is useful when a new minor release introduces a regression, which might take more than a week to fix in a new release. This is from my personal experience. |
That is both a rare occurrence and it rarely takes more than hours to fix, depending on the regression. I think when that happens and you're otherwise using the latest release, it's appropriate for you to jump through some hoops to lock it down. |
@ljharb Agreed. This whole suggestion came out of desire to keep latest |
Here's a mini spec for how I think this might work, in a way that maintains consistent behavior for how versions are specified and resolved. Does it make sense to you?
Upgrade procedure:
Examples:
NotesThe upgrade command is constrained to work only within the same major version because I assume that is the behavior people normally want for doing automatic upgrades. It could be possible for the Should there be an option for the upgrade command that will show you what it would do, without making any actual changes. Or a separate command? That was suggested above as |
LGTM |
An experimental implementation of this feature is in the NVS develop branch, if you want to try it out. I still need to add alias migration, tests, and documentation. |
Seems to work perfectly fine |
@jasongin Great job. Congratulations! |
It would be nice to somehow keep track of Node.js versions installed using version labels (not version numbers) to be able to upgrade them using a single command.
For instance, if I installed several Node.js versions using version labels:
nvs add argon
,nvs add boron
,nvs add latest
andnvs add nightly
, I would be able to upgrade all version labeled versions usingnvs up
/nvs upgrade
to the latest version ofargon
,boron
,latest
andnightly
.The text was updated successfully, but these errors were encountered: