Publishing runs automatically when a GitHub Release is published (see npm-publish.yml).
-
Merge the version bump on
master(or your release branch).package.jsonmust use a semver prerelease (a hyphen in the version, e.g.0.2.0-beta.0,0.2.0-rc.1). -
Create and push an annotated tag matching the version:
git checkout master && git pull git tag -a v0.2.0-beta.0 -m "v0.2.0-beta.0" git push origin v0.2.0-beta.0
-
On GitHub: Releases → Draft a new release → Choose tag
v0.2.0-beta.0→ describe changes → check Set as a pre-release (optional but recommended) → Publish release. -
The workflow publishes to npm with the
betadist-tag solateststays on the last stable version. Install with:npm install -g @bitrefill/cli@beta
-
Merge
package.jsonversion0.2.0(no prerelease suffix) and sync CLI/MCP version strings insrc/if you still duplicate them. -
Tag and push:
git tag -a v0.2.0 -m "v0.2.0" git push origin v0.2.0 -
Publish release on GitHub (not marked as pre-release). The workflow publishes as latest.
- npm: Trusted publishing (OIDC) for this repo, or a valid
NPM_TOKENif your org uses classic tokens instead. - Version: The tag should match the commit that contains the same
versioninpackage.jsonas what you intend to ship.