From 93bb1d6ca01197e9e915a71375b6955d67b3bf40 Mon Sep 17 00:00:00 2001 From: Eden Zimbelman Date: Tue, 1 Sep 2026 10:38:49 -0700 Subject: [PATCH] ci: migrate changesets/action release workflow to v2 changesets/action v2 renamed the root action's inputs and outputs (changesets/action#681) and now pushes release commits/tags via the GitHub API, requiring the token through the `github-token` input rather than the `GITHUB_TOKEN` env var (changesets/action#692). #133 bumped the action 1.9.0 -> 2.1.1 but left the release workflow on the v1 interface, so v2 would silently ignore the inputs, resolve the renamed output to empty, and lose the token. Inputs (renamed, alphabetized): version -> version-script publish -> publish-script createGithubReleases -> create-github-releases commit -> commit-message title -> pr-title prDraft -> pr-draft Outputs: publishedPackages -> published-packages Token: moved from `env: GITHUB_TOKEN` to the `github-token` input. Values unchanged; verified against action.yml at the pinned v2.1.1 SHA. Co-Authored-By: Claude --- .github/workflows/release.yml | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f4b65b4..cc3ffc6 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -40,20 +40,19 @@ jobs: id: changesets uses: changesets/action@8488615a623b1b9c987934bb89eae8af6a946ac1 # v2.1.1 with: - version: bash scripts/changeset_version.sh - publish: npx changeset publish - createGithubReleases: true - commit: "chore: release" - title: "chore: release" - prDraft: create - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + commit-message: "chore: release" + create-github-releases: true + github-token: ${{ secrets.GITHUB_TOKEN }} + pr-draft: create + pr-title: "chore: release" + publish-script: npx changeset publish + version-script: bash scripts/changeset_version.sh - name: Get publication details id: release if: steps.changesets.outputs.published == 'true' env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - PUBLISHED_PACKAGES: ${{ steps.changesets.outputs.publishedPackages }} + PUBLISHED_PACKAGES: ${{ steps.changesets.outputs.published-packages }} run: | echo "url=$(gh release view --json url -q .url)" >> "$GITHUB_OUTPUT" echo "message=$(echo "$PUBLISHED_PACKAGES" | jq -r '.[] | "\(.name)@\(.version)"' | paste -sd ', ' -)" >> "$GITHUB_OUTPUT"