Repository navigation
ci: publish packages on changeset version PR merge - #329
Merged
Merged
Conversation
Enable the previously commented publish step in the Changesets workflow so merging changeset-release/main into main runs changeset publish and ships the affected packages to npm. Implements SF-49.
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This branch was successfully deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Enable the
publishstep in the existingChangesetsworkflow so that merging theversion PR (
changeset-release/main) intomainpublishes the affected packages tonpm. Previously the workflow only opened/updated the version PR; the publish line was
commented out, so nothing ever shipped.
Why
Completes the release-automation half of the changesets flow: on push to
main,changesets/actioneither opens/updates the version PR (when changesets are present)or runs
changeset publish(when the version PR has merged and versions are alreadybumped). Implements SF-49.
Trigger path:
main.changesets/actionsees pending changesets → opens/updateschangeset-release/mainwith
pnpm ci:version(changeset version+ lockfile refresh).main→ no changesets remain → the action runspnpm exec changeset publish, pushingengine/*,theme, andtooling/*to npm.The build already runs in the prior "Build packages for release" step
(
pnpm run ci:prepublish→build:nodocs), so the publish command ischangeset publishdirectly rather thanci:publish(which would rebuild).Auth is already wired:
NPM_TOKEN/NODE_AUTH_TOKEN(set from theNPM_TOKENsecret, with
registry-urlconfigured onsetup-node) for the npm registry, and thedefault
GITHUB_TOKENfor the version PR.How verified
One-line diff (enable the previously commented publish step):
Notes
.github/workflows/changesets.ymlrather than adding a newrelease.yml— the singlechangesets/actionstep already handles both the versionPR and the publish, so duplicating it would race on the same branch.
NPM_TOKENrepo secret must be provisioned (an npmautomation token with publish rights to the styleframe npm scope). The workflow
references it but publishing will fail until it exists.