Skip to content

Commit 160a95b

Browse files
build: migrate Changesets CLI 3 and Action v2 atomically (#474)
* build(deps-dev): bump @changesets/cli from 2.31.1 to 3.0.1 Bumps [@changesets/cli](https://github.com/changesets/changesets/tree/HEAD/packages/cli) from 2.31.1 to 3.0.1. - [Release notes](https://github.com/changesets/changesets/releases) - [Changelog](https://github.com/changesets/changesets/blob/main/packages/cli/CHANGELOG.md) - [Commits](https://github.com/changesets/changesets/commits/@changesets/cli@3.0.1/packages/cli) --- updated-dependencies: - dependency-name: "@changesets/cli" dependency-version: 3.0.0 dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> * ci: migrate release workflow to Changesets Action v2 --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Brian Love <brian@liveloveapp.com>
1 parent 1138277 commit 160a95b

6 files changed

Lines changed: 309 additions & 545 deletions

File tree

.github/workflows/release.yml

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -82,27 +82,26 @@ jobs:
8282
8383
- name: Version PR or publish
8484
id: changesets
85-
uses: changesets/action@v1
85+
uses: changesets/action@v2
8686
with:
87-
version: pnpm exec changeset version
88-
publish: node ./scripts/publish-configured-packages.mjs
89-
title: "chore: version packages"
90-
commit: "chore: version packages"
91-
env:
92-
GITHUB_TOKEN: ${{ env.RELEASE_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
93-
# No NODE_AUTH_TOKEN. Publishing is OIDC-only: any token in the
94-
# environment makes npm use token auth and skip the trusted-publishing
95-
# exchange, which also means no provenance attestation. A package
96-
# without a trusted publisher must fail loudly here rather than fall
97-
# back to a token — see the preflight guard above.
87+
version-script: pnpm exec changeset version
88+
publish-script: node ./scripts/publish-configured-packages.mjs
89+
pr-title: "chore: version packages"
90+
commit-message: "chore: version packages"
91+
github-token: ${{ env.RELEASE_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
92+
# No NODE_AUTH_TOKEN. Publishing is OIDC-only: any token in the
93+
# environment makes npm use token auth and skip the trusted-publishing
94+
# exchange, which also means no provenance attestation. A package
95+
# without a trusted publisher must fail loudly here rather than fall
96+
# back to a token — see the preflight guard above.
9897

9998
- name: Enable auto-merge on Version PR
100-
if: steps.changesets.outputs.pullRequestNumber != '' && env.RELEASE_GITHUB_TOKEN != ''
99+
if: steps.changesets.outputs.pr-number != '' && env.RELEASE_GITHUB_TOKEN != ''
101100
env:
102101
GH_TOKEN: ${{ env.RELEASE_GITHUB_TOKEN }}
103102
run: |
104103
gh pr merge \
105104
--auto \
106105
--squash \
107106
--repo ${{ github.repository }} \
108-
${{ steps.changesets.outputs.pullRequestNumber }}
107+
${{ steps.changesets.outputs.pr-number }}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
},
4444
"devDependencies": {
4545
"@arethetypeswrong/cli": "^0.18.5",
46-
"@changesets/cli": "^2.31.1",
46+
"@changesets/cli": "^3.0.1",
4747
"@eslint/js": "^10.0.1",
4848
"@microsoft/api-extractor": "^7.59.0",
4949
"@microsoft/tsdoc": "^0.16.0",

0 commit comments

Comments
 (0)