ci: add WinGet publish workflow for release-based MSI submissions#131
ci: add WinGet publish workflow for release-based MSI submissions#131maximilian-schwaerzler wants to merge 5 commits intotonyantony300:mainfrom
Conversation
…for-winget-publishing ci: add automated WinGet publish workflow
📝 WalkthroughWalkthroughA GitHub Actions workflow was added to publish a Windows package to WinGet on release publish; it derives the package version from the release tag (strips leading Changes
🚥 Pre-merge checks | ✅ 1✅ Passed checks (1 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
There was a problem hiding this comment.
Actionable comments posted: 1
♻️ Duplicate comments (1)
.github/workflows/publish-winget.yml (1)
29-29:⚠️ Potential issue | 🟠 MajorFix MSI asset regex escaping to actually match filenames.
At Line 29,
'AltSendme_.*_x64_.*\\.msi'is over-escaped in a YAML single-quoted string and can miss valid.msiassets. This can block publishing.Proposed fix
- installers-regex: 'AltSendme_.*_x64_.*\\.msi' + installers-regex: '^AltSendme_.*_x64_.*\.msi$'#!/bin/bash # Verify current vs fixed regex behavior against a representative MSI filename. python - <<'PY' import re sample = "AltSendme_1.2.3_x64_en-US.msi" current = r"AltSendme_.*_x64_.*\\.msi" fixed = r"^AltSendme_.*_x64_.*\.msi$" print("sample:", sample) print("current fullmatch:", bool(re.fullmatch(current, sample))) # expected False print("fixed fullmatch:", bool(re.fullmatch(fixed, sample))) # expected True PY
There was a problem hiding this comment.
♻️ Duplicate comments (1)
.github/workflows/publish-winget.yml (1)
21-23: 🧹 Nitpick | 🔵 TrivialConsider explicit tag-format validation before stripping
v.At Line 23,
${TAG#v}assumes the tag shape implicitly. A quick validation makes failures faster to diagnose if someone publishes with an unexpected tag.Suggested hardening
run: | TAG="${{ github.event.release.tag_name }}" + if [[ ! "$TAG" =~ ^v[0-9]+(\.[0-9]+){1,3}$ ]]; then + echo "Unexpected tag format: $TAG (expected vX.Y or vX.Y.Z or vX.Y.Z.W)" + exit 1 + fi echo "tag=${TAG}" >> "$GITHUB_OUTPUT" echo "value=${TAG#v}" >> "$GITHUB_OUTPUT"
|
Thank you for this contribution, will review very soon. |
|
Added correction PR #135 |
Description
This PR adds automated WinGet publishing for AltSendme Windows releases.
What’s included
.github/workflows/publish-winget.yml.release.publishedand skips draft/prerelease releases.v.vedantmgoyal2009/winget-releaser@v2to submit/updateTonyAntony.AltSendme.AltSendme_*_x64_*.msi) and setsinstaller-type: wix.WINGET_TOKENfor authentication.CONTRIBUTING.md(workflow trigger, required secret, MSI preference rationale).Why MSI instead of NSIS?
MSI/WiX is preferred for WinGet reliability and enterprise/silent deployment compatibility.
Checklist
npm run lintbefore raising this PRnpm run formatbefore raising this PR