diff --git a/.agents/workflows/generate-release.md b/.agents/workflows/generate-release.md index 3a1c6c3c9c..e41fc474ac 100644 --- a/.agents/workflows/generate-release.md +++ b/.agents/workflows/generate-release.md @@ -52,19 +52,17 @@ Before creating the release, you must ensure the codebase and supply chain are s git checkout -b release/v2.x.y ``` -### 2. Determine new version - -Check current version in `package.json` and increment the **patch** number only: +### 2. Determine and sync version +Check current version in `package.json`: ```bash grep '"version"' package.json ``` -Version format: `2.x.y` — examples: - -- `2.1.2` → `2.1.3` (patch) -- `2.1.9` → `2.1.10` (patch) -- `2.1.10` → `2.2.0` (minor threshold — do manually with `sed`) +> **🔴 BRANCH-VERSION PARITY RULE**: The logical version in `package.json` MUST exactly match the release branch name. For example, if you are on `release/v3.7.0`, the version in `package.json` MUST be `3.7.0`. +> - If this is the FIRST time generating a release for a new minor/major branch (e.g., bumping from 3.6.9 to 3.7.0), you MUST ensure the version is bumped to match the new branch logic. +> - If you are just bumping a patch on the current branch (e.g., 3.6.9 to 3.6.10), use: +> `npm version patch --no-git-tag-version` > **⚠️ ATOMIC COMMIT RULE — Version bump MUST happen before committing feature files.** > @@ -97,15 +95,25 @@ npm install ### 4. Finalize CHANGELOG.md -Replace `[Unreleased]` header with the new version and date. -Keep an empty `## [Unreleased]` section above it. +> **🔴 NO MIXUPS RULE**: Ensure you do NOT mix the backlog of the previous version with the new one. The new version section must ONLY contain the features and fixes for the current release. + +Replace the `[Unreleased]` header with the new version and date. +Keep an empty `## [Unreleased]` section above it, separated by a horizontal rule (`---`). ```markdown ## [Unreleased] --- -## [2.x.y] — YYYY-MM-DD +## [3.7.0] — 2026-04-19 +### ✨ New Features +- ... +### 🐛 Bug Fixes +- ... + +--- + +## [3.6.9] — 2026-04-19 ``` ### 5. Update openapi.yaml version ⚠️ MANDATORY