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

winget upgrade for nvm is broken #876

Closed
remidebette opened this issue Nov 1, 2022 · 4 comments
Closed

winget upgrade for nvm is broken #876

remidebette opened this issue Nov 1, 2022 · 4 comments

Comments

@remidebette
Copy link

Issue:
Hi, thank you for the nice tool.

I am installing NVM for windows with winget, which is becoming the de facto tool for managing packages in Windows.

❯ winget install --id CoreyButler.NVMforWindows

My issue is that to this date I cannot seamlessly use the upgrade function of winget due to NVM for windows not been upgraded by the tool:

❯ winget upgrade --id CoreyButler.NVMforWindows
This package's version number cannot be determined. To upgrade it anyway, add the argument --include-unknown to your previous command.

Adding the --include-unknown parameter is not a good solution because I am never not in a state where the system is 'up to date'

You can see the main reason is that winget is unable to detect the current version of NVM for windows:

❯ winget upgrade --include-unknown
Name                                 Id                        Version Available Source
---------------------------------------------------------------------------------------
NVM for Windows                      CoreyButler.NVMforWindows Unknown 1.1.9     winget

Expected Behavior:
The actual version of the currently installed version should appear as so:

❯ winget upgrade --include-unknown
Name                                 Id                        Version Available Source
---------------------------------------------------------------------------------------
NVM for Windows                      CoreyButler.NVMforWindows 1.1.9   1.1.9     winget

Additional context:
As explained here: microsoft/winget-cli#1356
The version used by winget is simply the information provided from Control Panel
Apparently, all that is needed is to add a DisplayVersion key in the registry when installing.

See how the Control panel does not see the version:
image

Here is an example of a program with a version:
image

@coreybutler
Copy link
Owner

Duplicate of #851.

Also, DisplayVersion is available.

image

@alpturedi
Copy link

I think if you use the update utility it doesn't work so you probably need to use the installer to fix this.

@alpturedi
Copy link

I think if you use the update utility it doesn't work so you probably need to use the installer to fix this.

I can confirm that if you use the installer to update the version it fixes the issue.

@remidebette
Copy link
Author

This bug has been fixed in 1.1.10
When available from Winget, winget upgrade --include-unknown will also work

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

No branches or pull requests

3 participants