From b2b6356d6344ce3ee2dd8b74dcda21e27d6f1bef Mon Sep 17 00:00:00 2001 From: Chris Tate Date: Mon, 30 Mar 2026 20:54:59 -0500 Subject: [PATCH] fix release notes (#1097) * fix release notes * contributors note --- .github/workflows/release.yml | 14 +++++++++++++- AGENTS.md | 17 ++++++++++++++--- 2 files changed, 27 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 118f36a..11e958d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -291,6 +291,18 @@ jobs: - name: Create dashboard.zip run: cd packages/dashboard/out && zip -r ../../../dashboard.zip . + - name: Extract changelog entry + run: | + VERSION="${{ needs.check-release.outputs.version }}" + awk '//{found=1; next} //{found=0} found{print}' CHANGELOG.md > /tmp/release-notes.md + + LINES=$(wc -l < /tmp/release-notes.md | tr -d ' ') + if [ "$LINES" -lt 2 ]; then + echo "Error: No release notes found between and markers in CHANGELOG.md" + exit 1 + fi + echo "Extracted release notes for $VERSION ($LINES lines)" + - name: Create GitHub Release run: | VERSION="${{ needs.check-release.outputs.version }}" @@ -303,7 +315,7 @@ jobs: echo "Creating release $TAG..." gh release create "$TAG" \ --title "$TAG" \ - --generate-notes \ + --notes-file /tmp/release-notes.md \ bin/agent-browser-* dashboard.zip fi env: diff --git a/AGENTS.md b/AGENTS.md index f246736..c631638 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -41,21 +41,22 @@ To prepare a release: 1. Create a branch (e.g. `prepare-v0.24.0`) 2. Bump `version` in `package.json` 3. Run `pnpm version:sync` to update `cli/Cargo.toml`, `cli/Cargo.lock`, and `packages/dashboard/package.json` -4. Write the changelog entry in `CHANGELOG.md` at the top, under a new `## ` heading +4. Write the changelog entry in `CHANGELOG.md` at the top, under a new `## ` heading, wrapped in `` and `` markers 5. Add a matching entry to `docs/src/app/changelog/page.mdx` at the top (below the `# Changelog` heading) 6. Open a PR and merge to `main` -When the PR merges, CI compares `package.json` version to what's on npm. If it differs, it builds all 7 platform binaries, publishes to npm, and creates the GitHub release automatically. +When the PR merges, CI compares `package.json` version to what's on npm. If it differs, it builds all 7 platform binaries, publishes to npm, and creates the GitHub release automatically. The GitHub release body is extracted from the content between the `` and `` markers in `CHANGELOG.md`. ### Writing the changelog Review the git log since the last release and write the entry in `CHANGELOG.md`. Follow the existing format and voice. Group changes under `### New Features`, `### Bug Fixes`, `### Improvements`, etc. Bold the feature/fix name, then describe it concisely. Reference PR numbers in parentheses. -Example: +Wrap the release notes (everything between the `## ` heading and the previous version) in markers so CI can extract them for the GitHub release: ```markdown ## 0.24.0 + ### New Features - **Foo command** - Added `foo` command for bar (#1234) @@ -63,8 +64,18 @@ Example: ### Bug Fixes - Fixed **baz** not working when qux is enabled (#1235) + +### Contributors + +- @ctate +- @somecontributor + + +## 0.23.3 ``` +Include a `### Contributors` section listing the GitHub usernames (with `@` prefix) of everyone who contributed to the release. Check the git log between the previous tag and HEAD to find them. + Do not prefix entries with commit hashes. Do not use the changesets `### Patch Changes` / `### Minor Changes` headings. Use descriptive section names instead. ### Docs changelog