build(release): parameterize cut-release for the 2.0 line + document the 2.0 cut - #370
Merged
Conversation
cut-release.ps1 hard-coded develop for the pre-flight branch gate, the pushes, and the -PostReleaseOnly showcase flip. Add a -Branch parameter (default develop, common to both modes) and thread it through, so the 2.0 line cuts with -Branch 2.0-dev. Rename the pre-flight's local $branch to $currentBranch — PowerShell variables are case-insensitive, so it was clobbering the -Branch parameter (caught by the -DryRun). Promote -DryRun to a common parameter so -PostReleaseOnly can also be previewed. The pom-bump list already tolerates both layouts via the Test-Path guard (core/pom.xml is skipped on the old layout). The post-cut reminder now points at the Maven Central publish check instead of the retired JitPack build log.
Add a 2.0-cut section (2.G): the train is cut from 2.0-dev via cut-release.ps1 -Branch 2.0-dev, the -rc tag stays off Central, and the GA choreography cuts 1.x from the current main tip before fast-forwarding main to 2.0 and repointing develop. Add a note atop the pre-release checklist that maps the 1.9.x commands (-pl ., develop, aggregator/pom.xml) to their 2.0 forms (bare reactor verify, -pl :graph-compose-core, 2.0-dev, root pom + core/pom.xml).
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.
Why
cut-release.ps1hard-codeddevelopfor the pre-flight branch gate, the pushes, and the-PostReleaseOnlyshowcase flip, so it could not cut the 2.0 line (which releases from2.0-dev).docs/contributing/release-process.mddescribed only the 1.9.x flow. This is the last toolingprep before a 2.0.0-RC can be cut. (
release.yml's reactor gate already landed with the layoutmove.)
What
cut-release.ps1 -Branch(defaultdevelop, common to both modes) threads through thepre-flight gate, the pushes, the
-PostReleaseOnlyGH_BASE flip, and the post-cut reminders, sothe 2.0 line cuts with
-Branch 2.0-dev. The pom-bump list already handles both layouts via theTest-Pathguard (core/pom.xmlis skipped on the old single-jar layout). The post-cut remindernow checks the Maven Central publish instead of the retired JitPack build log.
$branch→$currentBranch: PowerShell variables arecase-insensitive, so the old local was clobbering the
-Branchparameter (the-DryRuncaught it — Step 8 was pushing the current git branch, and the branch gate compared the variable
to itself).
-DryRunto a common parameter so-PostReleaseOnlycan also be previewed (itsif ($DryRun)branches were previously unreachable — a parameter-set conflict).release-process.md§2.G — the 2.0 cut branch flow: cut from2.0-devviacut-release.ps1 -Branch 2.0-dev,-rctags stay off Central, and the GA choreography cuts1.xfrom the current
maintip before fast-forwardingmainto 2.0 and repointingdevelop. Plusa note atop the pre-release checklist mapping the 1.9.x command forms to their 2.0 equivalents.
Tests
pwsh cut-release.ps1 -Version 2.0.0-rc.1 -Branch 2.0-dev -DryRun→ previews the full 2.0 cut,bumps
core/pom.xml+ rootpom.xml+ the train, pushes2.0-dev(not the current branch),merge/flip reminders name
2.0-dev. Pushes/writes nothing.pwsh cut-release.ps1 -PostReleaseOnly -Branch 2.0-dev -DryRun→ flips GH_BASE to/blob/2.0-dev,pushes
2.0-dev, exit 0.pwsh cut-release.ps1 -Version 1.9.2 -DryRun(default branch) → stilldevelop: backward-compatible.CanonicalSurfaceGuardTest,DocumentationCoverageTest,PackageMapGuardTest) green.Build-script + docs only; no runtime change.