mirror of
https://github.com/NeuralNomadsAI/CodeNomad.git
synced 2026-07-10 00:14:27 +00:00
## Summary - add a release-published workflow that prepares and submits Winget manifest updates automatically - poll the GitHub Release API for the stable Windows Tauri asset and compute its SHA-256 before submission - document the maintainer secret and repository variables needed for the Winget automation flow ## Validation - `node --check "scripts/winget/resolve-release-asset.cjs"` - `node "scripts/winget/resolve-release-asset.cjs" --help` - dry-run resolver against the published `v0.16.0` release asset ## Notes - skips draft and prerelease GitHub releases - uses the maintainer fork submission flow for `microsoft/winget-pkgs` - live PR submission still depends on configuring `WINGET_GITHUB_TOKEN` - Fixes #462
1.9 KiB
1.9 KiB
Winget release automation
CodeNomad publishes Winget updates from GitHub Releases with .github/workflows/update-winget.yml.
Trigger
- Runs on
release.published. - Exits early for draft or prerelease releases.
- Waits for the expected stable Windows Tauri asset because the release record can exist before all assets finish uploading.
Required configuration
Repository secret
WINGET_GITHUB_TOKEN: Classic GitHub PAT withpublic_reposcope.- The token owner must own the fork that submits to
microsoft/winget-pkgs. - Komac-based submission cannot open the PR with a fine-grained token today.
- The token owner must own the fork that submits to
Repository variables
WINGET_PACKAGE_IDENTIFIER(default fallback in workflow:NeuralNomadsAI.CodeNomad)WINGET_FORK_OWNER(default fallback in workflow:pascalandr)WINGET_WINDOWS_ASSET_NAME_TEMPLATE(default fallback in workflow:CodeNomad-Tauri-windows-x64-{version}.zip)WINGET_ASSET_WAIT_TIMEOUT_SECONDS(optional, default fallback:900)WINGET_ASSET_POLL_INTERVAL_SECONDS(optional, default fallback:15)
{version} is replaced from the release tag after trimming a leading v.
Runtime flow
- Resolve the release version from
github.event.release.tag_name. - Poll the release API until exactly one uploaded asset matches the configured Windows Tauri asset template.
- Download the matched asset once and compute a SHA-256 for logging and verification.
- Verify the PAT owner matches
WINGET_FORK_OWNERand that${WINGET_FORK_OWNER}/winget-pkgsis a fork ofmicrosoft/winget-pkgs. - Invoke
vedantmgoyal9/winget-releaser@v2, which uses Komac under the hood to update the existingNeuralNomadsAI.CodeNomadmanifest and open the PR.
Notes
- The workflow does not depend on a persistent local
winget-pkgsclone. - The current package in
winget-pkgsuses the release ZIP with a nested NSIS installer, so the workflow targets the stableCodeNomad-Tauri-windows-x64-{version}.zipasset.