From 284eff8adeab77f1cff53342bad63eafcd382746 Mon Sep 17 00:00:00 2001 From: "Daniel D. Beck" Date: Mon, 22 Jul 2024 15:08:56 +0200 Subject: [PATCH] Document `NPM_TOKEN` (#1484) --- .prettierignore | 2 ++ docs/publishing.md | 23 +++++++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 docs/publishing.md diff --git a/.prettierignore b/.prettierignore index ec63ecc74c..7414278935 100644 --- a/.prettierignore +++ b/.prettierignore @@ -5,6 +5,8 @@ !GOVERNANCE.md !eslint.config.js +!/docs/publishing.md + !/features/*.yml /features/*.yml.dist diff --git a/docs/publishing.md b/docs/publishing.md new file mode 100644 index 0000000000..0e929c5eb1 --- /dev/null +++ b/docs/publishing.md @@ -0,0 +1,23 @@ +# Publishing + +## `@next` releases + +The [`publish_next_` GitHub Actions workflows](https://github.com/web-platform-dx/web-features/tree/main/.github/workflows) automatically publish pre-releases on push to the main branch using the `next` [npm dist tag](https://docs.npmjs.com/adding-dist-tags-to-packages). +You can install these prereleases using a command such as `npm install web-features@next`. + +## Secrets + +> [!NOTE] +> This information is for [project owners](../GOVERNANCE.md#roles-and-responsibilities). + +Publishing requires the `NPM_TOKEN` repository secret (set via _Settings_ → _Secrets and variables_ → _Actions_). +If you're replacing this token, then use the following settings: + +| Setting | Value | +| -------------------------------- | ---------------------------------------------------------------------------------------------------------- | +| Token type | _Granular Access Token_ | +| Expiration | The first day of the next quarter (1 January, 1 April, 1 July, or 1 October) or the first weekday after it | +| Packages and scopes permsissions | _Read and write_ | +| Select packages | _Only select packages and scopes_ | +| Select packages and scopes | `compute-baseline` and `web-features` | +| Organizations | _No access_ |