microsoft / winget-cli

WinGet is the Windows Package Manager. This project includes a CLI (Command Line Interface), PowerShell modules, and a COM (Component Object Model) API (Application Programming Interface).
https://learn.microsoft.com/windows/package-manager/
MIT License
22.53k stars 1.39k forks source link

Add `<PACKAGEVERSION>` token #4494

Open Trenly opened 1 month ago

Trenly commented 1 month ago

Description of the new feature / enhancement

With .zip installers, there are many instances where the relative file path to the exe or installer file between versions only changes based upon the version number. It would be useful if a token could be specified as part of the relative file path which is replaced with the package version.

This could also be useful for InstallationMetadata

A final use case could also be in URLs like ReleaseNotesUrl

Proposed technical implementation details

RelativeFilePath: .\setup\Package.1.2.3.exe => RelativeFilePath: .\setup\Package.<PACKAGEVERSION>.exe