Maintainer test — verifying the new agentic Duplicate Surfacing workflow (tracking: #6399). This issue intentionally duplicates an existing request and will be closed shortly after the run completes.
Relevant area(s)
WinGet CLI
Description of the new feature / enhancement
It would be great if the --location argument supported environment variable expansion natively, without relying on the shell. For example, I keep a set of per-app install-location overrides in a frontend and want them to be portable across machines, where the same path resolves differently (different drive letters, user profiles, etc.).
Having winget expand environment variables in --location itself — independent of the calling shell or app — would make those overrides portable.
Proposed technical implementation details
Since / : * ? " < > | are illegal in folder names, a delimiter like <VAR> could denote an environment variable, e.g. --location "<SystemDrive>\Program Files\my-app" would expand <SystemDrive> to C:.
Relevant area(s)
WinGet CLI
Description of the new feature / enhancement
It would be great if the
--locationargument supported environment variable expansion natively, without relying on the shell. For example, I keep a set of per-app install-location overrides in a frontend and want them to be portable across machines, where the same path resolves differently (different drive letters, user profiles, etc.).Having winget expand environment variables in
--locationitself — independent of the calling shell or app — would make those overrides portable.Proposed technical implementation details
Since
/ : * ? " < > |are illegal in folder names, a delimiter like<VAR>could denote an environment variable, e.g.--location "<SystemDrive>\Program Files\my-app"would expand<SystemDrive>toC:.