Enable Go auto-release on main CI - #27151
Merged
Merged
Conversation
Allow internal post-merge CI runs to include the Go release stages and gate automatic releases on the auto-release prepare stage outputs. Preserve manual release behavior by keeping non-CI release runs gated only on the existing release checks. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Ray Chen (raych1)
requested review from
Ben Broderick Phillips (benbp) and
Mike Harder (mikeharder)
as code owners
July 8, 2026 22:20
Contributor
There was a problem hiding this comment.
Pull request overview
This PR enables automated Go package releases to run on post-merge main CI builds (Build.Reason = IndividualCI), whereas previously the Prerelease/Release stages only ran on Manual/empty build reasons or forced IncludeRelease. It wires a new shared AutoReleasePrepare stage into the Go release template and gates the Release stage on that stage's outputs (auto-release label present + changed-package signal) in addition to the existing NeedToRelease changelog/tag gate, while leaving the manual release path unchanged.
Changes:
- Add
IndividualCIto the build-reason condition inarchetype-sdk-client.ymlso the Go release template is included on post-merge main CI. - Conditionally insert an
AutoReleasePreparestage (from a sharedeng/commontemplate) beforeReleaseonIndividualCIbuilds. - Make the
Releasestage additionally depend onAutoReleasePrepareand require itsAutoReleaseLabelPresent/HasAutoReleaseArtifactsoutputs onIndividualCI, preserving the original gate for other build reasons.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| eng/pipelines/templates/jobs/archetype-sdk-client.yml | Adds IndividualCI to the build-reason gate so the release template is included on post-merge main CI. |
| eng/pipelines/templates/jobs/archetype-go-release.yml | Adds a conditional AutoReleasePrepare stage and extends the Release stage's dependsOn/condition to require its auto-release outputs on IndividualCI. |
Daniel Jurek (danieljurek)
approved these changes
Jul 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
IndividualCIbuilds so auto-release can run after a PR merges tomainAutoReleasePreparestage beforeReleaseon main CI buildsNeedToReleasegate plus auto-release label and changed-package signals for main CI, while preserving the manual release path