Releasing with Changesets
How to cut a release from a repository configured for Changesets.
Cut a release
Ship a changeset with every user-facing change:
yarn changeset
Pick the affected packages and the semver bump; it writes a markdown file under .changeset/. Commit it alongside the change.
Continuous delivery
Pushes to the default branch should be handled by the release workflow:
changeset versionconsumes the pending changesets — bumpspackage.json, rewrites eachCHANGELOG.md, deletes the changeset files — and opens or updates a "Version Packages" pull request.- Merging that pull request leaves nothing to version, so the workflow runs
changeset publish, which builds each package (prepublishOnly→yarn build) and publishes it to GitHub Packages with the workflow'sGITHUB_TOKEN. No extra secrets are needed.
Manual fallback
To cut a release by hand, version and publish in two steps:
yarn version
NODE_AUTH_TOKEN=<PAT with write:packages> yarn release
The token needs write:packages on the target repository.