You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+17-12Lines changed: 17 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -50,16 +50,21 @@ make benchmark
50
50
51
51
## Cutting a release
52
52
53
-
Cutting a release is currently a manual process. We use a [Conventional Changelog](http://conventionalcommits.org/) to simplify the process of managing semver on this project. Generally, the following series of commands will cut a release from the `master` branch:
53
+
Releases are automated with [release-please](https://github.com/googleapis/release-please) and published to npm via GitHub Actions. We use [Conventional Commits](http://conventionalcommits.org/) to simplify the process of managing semver on this project — release-please parses commit types (`fix`, `feat`, etc.) to determine the version bump.
54
54
55
-
```
56
-
$ git fetch
57
-
$ git pull origin master # ensure you have the latest changes
58
-
$ npx unleash [-p for patch, -m for minor, -M for major] --no-publish -d # do a dry run to verify
59
-
$ npx unleash [-p for patch, -m for minor, -M for major] --no-publish
60
-
# Unleash doesnt support 2FA, hence we use --no-publish flag here.
61
-
# This ensures we have the package.json updated, changelog generated, tag created
62
-
# and all the changes into origin
63
-
# Next, publish to npm manually and do not forget to provide the 2FA code.
64
-
$ npm publish
65
-
```
55
+
### Release flow
56
+
57
+
1. Merge pull requests to `master` using [Conventional Commits](http://conventionalcommits.org/).
58
+
2.`release-please` opens or updates a **Release PR** with the version bump and changelog.
59
+
3. Review and merge the Release PR when ready to ship.
60
+
4.`release-please` creates a GitHub Release and version tag (for example `v11.3.0`).
61
+
5. The `npm-publish` workflow runs automatically, re-runs tests, validates the package contents (`npm pack --dry-run`), then pauses at the `Publish` environment for reviewer approval.
62
+
6. After approval, the package is published to npm via [Trusted Publishing](https://docs.npmjs.com/trusted-publishers) (OIDC). Do not run `npm publish` manually.
63
+
64
+
### Dry run
65
+
66
+
To validate the publish workflow without publishing, run **Actions → npm-publish → Run workflow**. This runs tests and `npm pack --dry-run`.
67
+
68
+
### Retrying a failed run
69
+
70
+
If `npm-publish` fails, use **Re-run jobs** on the failed run itself (Actions tab) — it replays the same release/tag, so there's no need to cut a new one. This is safe even if `publish` partially ran, since `validate` checks whether the version is already on npm before continuing.
0 commit comments