From 1a3251bb5d6e0610dbe1e4a0d7ccd7d662c5115a Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 27 Sep 2026 21:13:06 +0000 Subject: [PATCH] ci(release): lead the release body with its changelog section Studio reads the catalog release body before offering an update and lists the changeset summaries it finds there. The generated notes are PR titles, so the body now starts with this version's CHANGELOG.md section and keeps the generated list after it. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_011fP3oaCegEv3nsGYanvaod --- .github/workflows/release.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 58bb76583..590de0754 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -154,12 +154,32 @@ jobs: echo "exists=false" >> $GITHUB_OUTPUT fi + # Studio shows this release's body before it offers a catalog update, + # parsing the `- : summary` changeset lines into a short + # what's-new list. GitHub's generated notes are PR titles, which + # Studio ignores, so the body leads with this version's CHANGELOG + # section and the generated list follows it for maintainers. The + # version reaches awk through `env:`, never interpolated into `run:`. + - name: Extract release notes from CHANGELOG + if: steps.changesets.outputs['has-changesets'] == 'false' && steps.tag_check.outputs.exists == 'false' + env: + VERSION: ${{ steps.pkg.outputs.version }} + run: | + set -euo pipefail + awk -v heading="## ${VERSION#v}" \ + '$0 == heading { found = 1; next } /^## / && found { exit } found' \ + CHANGELOG.md > dist/release-notes.md + if [ ! -s dist/release-notes.md ]; then + echo "::warning::CHANGELOG.md has no section for ${VERSION}; the release body will carry only the generated notes." + fi + - name: Create GitHub Release if: steps.changesets.outputs['has-changesets'] == 'false' && steps.tag_check.outputs.exists == 'false' uses: softprops/action-gh-release@3d0d9888cb7fd7b750713d6e236d1fcb99157228 # v3 with: tag_name: ${{ steps.pkg.outputs.version }} name: Catalog ${{ steps.pkg.outputs.version }} + body_path: dist/release-notes.md generate_release_notes: true files: | dist/catalog.sqlite