ci: auto-tag releases from conventional-commit prefixes on main - #414
ci: auto-tag releases from conventional-commit prefixes on main#414defangdevs wants to merge 1 commit into
Conversation
Main has drifted 100+ commits past the last tag (v2.5.2) with no release cut, so merged fixes/features/dep bumps sit unpublished for weeks. This runs after `test` passes on main and pushes the next vX.Y.Z tag (major on `!`/BREAKING CHANGE, minor on feat:, patch otherwise), which is all release.yml needs to build and publish everything.
|
Warning Review limit reached
Next review available in: 1 minute Limit details: You’ve used all 1 included review currently available under your plan. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
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 |
| - name: Checkout tested commit | ||
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v6 | ||
| with: | ||
| ref: ${{ github.event.workflow_run.head_sha || github.sha }} | ||
| fetch-depth: 0 | ||
| fetch-tags: true | ||
|
|
||
| # Classifies commits since the last vX.Y.Z tag using the Conventional | ||
| # Commits prefixes already in use on this repo (feat:, fix:, | ||
| # chore(deps):, etc.) and picks the next semver tag. Pushing that tag | ||
| # (next step) is all release.yml needs to build+publish everything. | ||
| - name: Determine next version |
lionello
left a comment
There was a problem hiding this comment.
Why wouldn't we add this to the main workflow? Seems like we'd be able to skip some steps.
Why
Main has drifted 116 commits past the last release (v2.5.2, 2026-07-11) with no tag cut since — includes the alarms (352), serviceIds (354), dev-deploy-blockers (353), and Azure BYOD DNS (305) features, plus a month of dependabot bumps and CI fixes, all merged but unpublished.
What this does
New workflow
auto-release.yml:testcompleting successfully onmain(or manualworkflow_dispatch).vX.Y.Ztag, classifies by the Conventional Commits prefixes already used in this repo's history (feat:→ minor,!/BREAKING CHANGE→ major, anything else that landed → patch — sofix:,chore(deps):,ci:, etc. still ship rather than piling up unreleased).release.yml's existingpush: tags: v*.*.*trigger does the rest (builds, publishes SDKs + CD images) — no changes to that pipeline.Dry-run against the real history:
v2.5.2..main→ minor bump → v2.6.0 (multiplefeat:commits, e.g. serviceIds, alarms, Azure BYOD DNS).Required setup before this can actually publish
GITHUB_TOKEN-authored pushes don't trigger other workflows — if the tag-push step used the default token, the tag would be created but
release.ymlwould never fire. The tag-push step usessecrets.RELEASE_PATinstead, which doesn't exist yet. Needs a PAT (or bot/App token) withcontents: writeon this repo, added as a repo secret namedRELEASE_PAT, before merging — otherwise the workflow will compute the right version and then fail on push.Test plan
actionlintclean (matches repo's SHA-pin + shellcheck conventions)v2.5.2..mainreal commit history (see above)RELEASE_PATsecret added