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
{{ message }}
Repository navigation
Commit 78cc995
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+37-5Lines changed: 37 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -70,13 +70,45 @@ The documentation is a part of the website, which is stored in `website` directo
70
70
71
71
### Publishing a release
72
72
73
-
We use [changesets](https://github.com/changesets/changesets) to automate to bump the version, update `CHANGELOG.md` files in published packages and publish to NPM registry. If you have publish access to the NPM `@callstack` scope, run the following from the default branch (usually `main` branch) to publish a new release:
73
+
We use [changesets](https://github.com/changesets/changesets) and the
74
+
[Changesets GitHub Action](https://github.com/changesets/action) to bump package
75
+
versions, update package `CHANGELOG.md` files, publish to npm, and create GitHub
76
+
releases.
74
77
75
-
```sh
76
-
pnpm release
77
-
```
78
+
#### Stable releases
78
79
79
-
NOTE: You must have a `GITHUB_TOKEN` environment variable available. You can create a GitHub access token with the "repo" access [here](https://github.com/settings/tokens).
80
+
When releasable changesets are merged to `main`, the `Release` workflow creates
81
+
or updates a `chore: changeset version` pull request. This PR contains the exact
82
+
package version changes and generated changelog entries for the next release.
83
+
84
+
Review the version numbers and changelog entries in that PR before merging it.
85
+
When the version PR is merged to `main`, the same workflow runs `pnpm release`,
86
+
publishes the packages to npm, pushes the release tags, and creates GitHub
87
+
releases from the generated changelog entries.
88
+
89
+
#### Canary releases
90
+
91
+
Canary releases are published manually from the `Release` workflow in GitHub
92
+
Actions. Run it only from the `main` branch. The workflow creates snapshot
93
+
versions with the `canary` snapshot label, runs the full release checks, and
94
+
publishes with the `canary` npm dist-tag without committing version changes or
95
+
creating GitHub releases.
96
+
97
+
#### npm trusted publishing
98
+
99
+
Releases use npm trusted publishing instead of long-lived npm automation tokens.
100
+
Do not add `NPM_TOKEN` or `NODE_AUTH_TOKEN` secrets for publishing.
101
+
102
+
Each published package in the `@callstack` scope must have trusted publishing
103
+
configured on npmjs.com with GitHub Actions as the publisher:
104
+
105
+
- Owner: `callstack`
106
+
- Repository: `repack`
107
+
- Workflow file: `release.yml`
108
+
- Allowed action: `npm publish`
109
+
110
+
The release workflows intentionally disable package-manager caching to avoid
0 commit comments