Repository navigation
Conversation
Add shell and PowerShell manifest generators. Generate and validate manifests in the release workflow. Publish through the GitHub API without cloning winget-pkgs. Supersede the winget-releaser workflow from #496.
Run the version helper from the repository root. Avoid GNU dirname and cd options.
Use an explicit empty CDPATH for the script directory lookup.
Create the new version commit on the fork master. The PR adds only the new version directory.
Use a fine-grained token for fork branch and commit writes. Use a classic public_repo token for the upstream pull request.
Match the token name to the WINGET_FORK_OWNER variable. The PR token stays WINGET_PR_TOKEN.
inqrphl
commented
Nov 16, 2026
| $message = if ($isNewPackage) { "New package: $packageIdentifier $packageVersion" } else { "Update $packageIdentifier to $packageVersion" } | ||
| # The fork master can be behind upstream. | ||
| # The PR adds only the new version directory, so the fork does not need to be current. |
Contributor
Author
There was a problem hiding this comment.
the most complicated part of the PR, and the hardest script section starts here.
uses the github HTTP API to create a new branch, upload files as blobs? , generates a commit JSON, uploads it etc.
Did not look into the references for every API call here.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
AI GENERATED
Summary
This PR turns the WinGet manifests into templates.
It generates the manifests during the release workflow.
It validates the generated manifests with
winget validate.It attaches the manifests to the draft release.
It publishes the manifests through the GitHub API without cloning winget-pkgs.
It supersedes #496.
Package identifier
The package identifier stays
ConSol.SNClient.Two versions
TAG_VERSIONis the release tag without the leadingv.PACKAGE_VERSIONis the MSIProductVersionand the ARPDisplayVersion.WinGet
PackageVersionmust match the installed MSI.Installer URLs use
TAG_VERSION.The generated manifests are in
packaging/winget/<package-version>/.What changed
packaging/winget/templates/*.yaml.in.buildtools/winget_manifests.sh.buildtools/winget_manifests.ps1.buildtools/get_winget_version.winget-manifestsMakefile target.packaging/winget/.gitignorefor generated version directories.pkg-wingetto the release workflow.upload-winget-manifeststo attach the zip to the draft release..github/workflows/winget.ymlfor API publishing.WINGET_FORK_TOKENandWINGET_PR_TOKEN.packaging/RELEASE.md.build_msi.ps1is unchanged.The PowerShell generator reads
ProductCode,ProductVersionand SHA256 from the MSIs.Release and publish flow
pkg-wingetreads the MSIs and generates the manifests.pkg-wingetrunswinget validate.pkg-wingetcreatessnclient-<tag>-winget-manifests.zip.upload-winget-manifestsattaches the zip to the draft release.WINGET_FORK_TOKENcreates the branch and commit in the fork.WINGET_PR_TOKENopens the PR inmicrosoft/winget-pkgs.The publish workflow uses the GitHub API to create blobs, a tree, a commit and a branch in the fork.
The classic token opens the PR in
microsoft/winget-pkgs.It does not clone the 500k-commit winget-pkgs repository.
A fork is still required for the PR head branch.
The fork does not need to be current.
The commit is based on the fork master.
The PR adds only the new version directory.
The PR can show an out-of-date branch.
That is expected.
Automation switch
WINGET_AUTOPUBLISHis set tofalsein the repository.The release job is skipped while it is false.
Set it to
trueafter the first package is merged.Manual
workflow_dispatchruns withdry_run=trueby default.Set
dry_run=falseto publish manually.Setup:
microsoft/winget-pkgs.WINGET_FORK_OWNERtoinqrphl.WINGET_FORK_TOKEN.Contents: Read and writeoninqrphl/winget-pkgs.public_repoasWINGET_PR_TOKEN.microsoft/winget-pkgs.Supersedes #496
#496 used
vedantmgoyal9/winget-releaserand the identifierConSolMonitoring.SNClient.It also used the release tag as the package version, which would be
1.02instead of1.02.0.This PR keeps the release trigger and the fork setup.
It replaces the action with the generated manifests and the API publisher.
It uses
ConSol.SNClientand the MSI version.Validation
winget validatesucceeded on the generated 1.01.0 manifests.winget validateon every release.Reviewer test on Linux:
Reviewer test on Windows:
First submission
The first v1.01.0 submission is manual.
Generate the 1.01.0 manifests from the three release MSIs.
Copy them to
manifests/c/ConSol/SNClient/1.01.0/.WINGET_AUTOPUBLISHstays false until that PR is merged.Checklist
winget validateof the generated 1.01.0 manifests.pkg-wingetjob runs on the next tag.