feat: support beta releases from any branch
Closes #2250
What
The publish workflow was hardcoded to always build from and push back to main. This PR makes the source branch configurable so beta releases can be triggered from any branch without touching main.
Changes
publish.yml
| Area | Before | After |
|---|---|---|
workflow_dispatch inputs | channel, dry_run, release_notes | Added branch input (default: main) |
Checkout step | Always checked out default ref | Checks out inputs.branch via ref: |
Commit patched Info.plist | Hardcoded origin/main rebase + push | Uses inputs.branch dynamically |
gh release create | No --target, defaulted to repo default branch | --target ${{ inputs.branch }} |
concurrency.group | publish-${{ inputs.channel }} | publish-${{ inputs.branch }}-${{ inputs.channel }} — parallel beta runs from different branches no longer cancel each other |
build.sh is untouched — it was already branch-agnostic.
Usage after this PR
Trigger a beta from a feature branch:
gh workflow run publish.yml \
--ref main \
--field branch=feature/my-feature \
--field channel=beta \
--field dry_run=false
Or via the GitHub Actions UI: select the workflow, set Branch to your feature branch, channel to beta.
Main-based releases are unaffected — branch defaults to main, so existing usage requires no changes.
Summary by Sourcery
Allow the publish workflow to create beta releases from any branch instead of being hardcoded to main.
New Features:
- Add a configurable workflow_dispatch input to choose the source branch for releases.
Enhancements:
- Make checkout, plist commit, and GitHub release targeting branch-aware based on the provided input.
- Update workflow concurrency grouping to include branch name so runs from different branches do not cancel each other.
- Improve inline documentation to describe branch-based release behavior and recovery steps.
Summary by cubic
Enable beta and stable releases from any branch without touching main. Default behavior is unchanged—set the branch input to release from another branch. Addresses #2250.
-
New Features
- Added
branchinput (defaultmain); checkout and theInfo.plistbump targetinputs.branch. - Release job checks out the released tag;
gh release createrelies on the tag (no--target).
- Added
-
Bug Fixes
- Concurrency scoped to
inputs.branch+ channel;inputs.branchvalidated viagit check-ref-format --branchand passed via env in shell steps. - Consolidated git identity; SHA-pinned
actions/upload-artifactandactions/download-artifact; added a tag reachability guard before creating a release. - Docs consolidated: removed
docs/RELEASING.md, merged guidance intodocs/development.md(feature-branch betas, tag-collision recovery), and expanded workflow comments with collision recovery,CHANNELinterpolation safety, and tag-injection notes.runbot-hq/afm-release-notes-actionremains@mainby design.
- Concurrency scoped to
Summary by CodeRabbit
- New Features
- Added a manual release option to choose the source branch (default:
main) for checkout, build, and publishing.
- Added a manual release option to choose the source branch (default:
- Bug Fixes
- Improved workflow concurrency isolation by scoping cancellation to both branch and release channel.
- Strengthened release workflow safeguards around branch validity and tag targeting before creating GitHub releases.
- Documentation
- Added
docs/RELEASING.md, detailing beta/stable/dry run triggers, version/tag rules, and recovery steps for partial failures.
- Added