Skip to content

Commit 58d47d9

Browse files
committed
ci: publish beta and rc tags as prereleases
The tag-driven release path already builds and publishes everything; the one thing separating a release from a beta was that nothing ever passed --prerelease. Tags matching *-beta* or *-rc* now do, on both the create and the re-run path. That flag is the whole beta channel. The in-app updater asks the API for /releases/latest, which GitHub defines as the newest non-prerelease, and the Manager UI links to the web releases/latest, which resolves the same way - so testers install betas from the releases page while every installed copy keeps updating to stable. Verified against all three release consumers in the tree; the third is the score parser's own repo and unaffected. Cutting a beta is: write the drop note into RELEASE_NOTES.md on the branch, tag v3.0-beta.N, push the tag. Stable and 3.0-final publishing is untouched.
1 parent b0ebb07 commit 58d47d9

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

.github/workflows/build.yml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -463,11 +463,20 @@ jobs:
463463
release/manifest.json
464464
)
465465
466+
# A beta or rc tag publishes as a prerelease. That is the whole beta
467+
# channel: the in-app updater asks /releases/latest, which GitHub
468+
# defines as the newest non-prerelease, so testers grab these from the
469+
# releases page while every installed copy keeps updating to stable.
470+
flags=()
471+
if [[ "${GITHUB_REF_NAME}" == *-beta* || "${GITHUB_REF_NAME}" == *-rc* ]]; then
472+
flags+=(--prerelease)
473+
fi
474+
466475
if gh release view "${GITHUB_REF_NAME}" >/dev/null 2>&1; then
467-
gh release edit "${GITHUB_REF_NAME}" --notes-file RELEASE_NOTES.md
476+
gh release edit "${GITHUB_REF_NAME}" --notes-file RELEASE_NOTES.md "${flags[@]}"
468477
gh release upload "${GITHUB_REF_NAME}" "${assets[@]}" --clobber
469478
else
470479
gh release create "${GITHUB_REF_NAME}" "${assets[@]}" \
471480
--notes-file RELEASE_NOTES.md \
472-
--verify-tag
481+
--verify-tag "${flags[@]}"
473482
fi

0 commit comments

Comments
 (0)