Skip to content

chore: add release PR workflow and npm provenance#2434

Merged
joshuaellis merged 4 commits into
nextfrom
chore/release-workflow-provenance
May 21, 2026
Merged

chore: add release PR workflow and npm provenance#2434
joshuaellis merged 4 commits into
nextfrom
chore/release-workflow-provenance

Conversation

@joshuaellis

Copy link
Copy Markdown
Member

Summary

Introduces a bot-maintained "Version Packages" PR for next and migrates the publish path to npm Trusted Publishing so every published tarball carries a verifiable SLSA provenance attestation.

What the new workflow does

  • Push to next with unconsumed changesets → opens/updates a chore: version packages PR with the version bumps. Nothing publishes.
  • Push to next without unconsumed changesets (i.e. the version PR was just merged) → runs pnpm changeset publish, which publishes only packages whose package.json version is newer than what's on npm.

Provenance is auto-attached because the job runs with id-token: write and the npm CLI ≥ 11.5.1 detects the OIDC environment. After publish, run npm audit signatures on a consumer machine to verify, or look for the green "Built and signed on GitHub Actions" badge on each npm package page.

Manual setup already completed on npmjs.com

Trusted Publisher → GitHub Actions added for all 12 publishable packages (react-spring, @react-spring/{animated,core,parallax,rafz,shared,types,konva,native,three,web,zdog}) pointing at pmndrs/react-springrelease.yml.

Other corrections folded in

  • .changeset/config.json baseBranch was still main despite the active line being next — fixed.
  • changelog switched on (@changesets/changelog-github) so release PR bodies link each entry to its source PR.
  • Existing nightly.yml / experimental.yml now also attach provenance to their snapshot publishes via id-token: write + NPM_CONFIG_PROVENANCE=true in scripts/version-and-publish.sh. They continue to use NPM_TOKEN for now; migrating those flows to Trusted Publishing is a follow-up.

@changeset-bot

changeset-bot Bot commented May 21, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: e3e3bf1

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel

vercel Bot commented May 21, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
react-spring Ready Ready Preview May 21, 2026 7:32pm

Request Review

Adds a changesets-driven Release workflow that opens a "Version Packages"
PR on `next` and publishes when the PR is merged, with every tarball
signed via npm Trusted Publishing (OIDC, no NPM_TOKEN).

Also attaches SLSA provenance to the existing nightly and experimental
publishes via id-token: write + NPM_CONFIG_PROVENANCE=true, fixes the
stale baseBranch in .changeset/config.json (main -> next), and enables
@changesets/changelog-github so release PR bodies link back to source PRs.
Tests already pass on the PR via tests.yml before merge to next, so re-running them on the release path just adds latency.
@joshuaellis joshuaellis force-pushed the chore/release-workflow-provenance branch from 74df912 to e3e3bf1 Compare May 21, 2026 19:30
@joshuaellis joshuaellis merged commit 7a6545f into next May 21, 2026
21 checks passed
@joshuaellis joshuaellis deleted the chore/release-workflow-provenance branch May 21, 2026 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant