chore: adopt Changesets for release-note generation #7
Workflow file for this run
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
| name: Verify changesets | |
| on: | |
| pull_request: | |
| types: [opened, synchronize, reopened] | |
| branches: [main] | |
| # Advisory check: runs `changeset status` and surfaces the result in the | |
| # CI summary panel. A missing changeset is flagged but does not block merge. | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: verify-changesets-${{ github.event.pull_request.number }} | |
| cancel-in-progress: true | |
| jobs: | |
| status: | |
| runs-on: ubuntu-latest | |
| if: github.event.pull_request.head.repo.full_name == github.repository | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| fetch-depth: 0 | |
| - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 | |
| with: | |
| node-version-file: .nvmrc | |
| cache: npm | |
| - run: npm ci --no-audit --no-fund | |
| - name: Release-doc invariants (CHANGELOG bullet shape; CLAUDE.md symlink; config shape) | |
| run: npm run check:release-docs | |
| - name: Release-doc invariant tests (positive + negative path) | |
| run: npm run test:release-docs | |
| - id: status | |
| continue-on-error: true | |
| run: npx --no -- changeset status --since=origin/${{ github.event.pull_request.base.ref }} | tee status.txt | |
| - name: Summary | |
| env: | |
| REPO_URL: ${{ github.server_url }}/${{ github.repository }} | |
| run: | | |
| { | |
| echo "## Changesets status" | |
| if [ "${{ steps.status.outcome }}" = "success" ]; then | |
| echo "Changeset coverage looks fine." | |
| else | |
| echo "No changesets detected on a PR that touches workspace packages." | |
| echo "" | |
| echo "Run \`npm run changeset\` and commit the resulting file, or skip if this PR only touches docs / CI / refactors. Rules: ${REPO_URL}/blob/main/docs/development/release-notes.md" | |
| fi | |
| echo "" | |
| echo "<details><summary>changeset status</summary>" | |
| echo "" | |
| echo '```' | |
| cat status.txt 2>/dev/null || true | |
| echo '```' | |
| echo "" | |
| echo "</details>" | |
| } >> "$GITHUB_STEP_SUMMARY" |