UniGetUI icon indicating copy to clipboard operation
UniGetUI copied to clipboard

[IMPROVEMENT] Do not follow the --location argument when upgrading [winget]

Open mos1128 opened this issue 2 months ago • 3 comments

Please confirm these before moving forward.

  • [x] I have searched for my feature proposal and have not found a work-in-progress/duplicate/resolved/discarded issue.
  • [x] This improvement refers to an existing feature. If you want to suggest a new feature, please use this template.
  • [x] This improvement is not a bug. If you want to report a bug, please use this template.

Describe the improvement

When using unigetui to manage software packages, I configured the default installation path for Winget (e.g., D:\wingetApps{package}). However, when updating previously installed software (for example, originally installed at C:\Program Files\SomeApp), the new version is forcibly installed to the default path D:\wingetApps, instead of the software's original installation path.

Describe how this improvement could help users

The software path remains organized, preventing any instances of duplicate installations.

mos1128 avatar Oct 29 '25 05:10 mos1128

I am afraid this is a default winget behaviour, when passed the --location argument the package will be upgraded there, and not on the original location.

To fix this, you can: a) Migrate your existing software b) Override default install options for conflicting packages, clearing the "Install Location" field

marticliment avatar Oct 29 '25 09:10 marticliment

I suggest considering whether to omit the --location parameter during updates and instead use winget's default update behavior. This way, even if I pre-install the software and later manage it with UnigetUI, it will not affect the original installation path.

mos1128 avatar Oct 29 '25 13:10 mos1128

I see.

marticliment avatar Oct 30 '25 08:10 marticliment