Open mdanish-kh opened 10 months ago
I would say that the update
command doesn't seem like a logical home for this functionality to me - although I understand it is because there isn't all the option available in the new
command.
I know it's a bit pedantic, but instead of --new-package-id
parameter, I would rather see it the other way - where you specify the base package as the parameter. To me it seems clearer that this is creating a new identifier rather than a new version in an existing one. It might also make implementation easier, but I'm not sure.
wingetcreate update Python.Python.3.$(minorVersion) --urls <urls> --version 3.15.3 --base-package Python.Python.3.10
Description of the new feature / enhancement
Some packages have their PackageIdentifier broken into each minor version.
Examples are:
UI-Xaml:
Microsoft.UI.Xaml.2.7
,Microsoft.UI.Xaml.2.8
Python:
Python.Python.3.9
,Python.Python.3.10
Currently the submissions for these packages cannot be fully automated through winget-create as it requires adding them under a new PackageIdentifier for every minor version bump.
Proposed technical implementation details
Support something like
--new-package-id <NewPackageIdentifier>
for update command.That way, a publisher can add code in the release pipeline that checks if the minor version is bumped which then uses this option to update and add the package in the new PackageIdentifier.
I'm thinking something like this in the release yaml file
This will always use the 3.10 manifest as the base manifest. If directory for $minorVersion already exists in repo, it will add the package under that directory else create a new PackageId/directory for it
The design is just off the top of my head and I would love to hear feedback for the proposed flow