Skip to content

Commit 3a0b18f

Browse files
authored
Support publishing packages with provenance (#1161)
By enabling the `--provenance` flag during `npm publish`, our package now includes a verifiable record of its build process, enhancing supply chain security. This helps others confirm the authenticity and integrity of the package, ensuring greater trustworthiness in the ecosystem. See - https://docs.npmjs.com/generating-provenance-statements#publishing-packages-with-provenance-via-github-actions - https://github.blog/security/supply-chain-security/introducing-npm-package-provenance/
1 parent fd8ac95 commit 3a0b18f

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.github/workflows/release.yml

+5
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,11 @@ on:
1010

1111
jobs:
1212
release-package:
13+
permissions:
14+
contents: read
15+
id-token: write
16+
issues: write
17+
1318
runs-on: ubuntu-latest
1419
steps:
1520
- uses: actions/checkout@v4

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"docs:build": "vitepress build docs",
4747
"docs:preview": "vitepress preview docs",
4848
"apidocs": "typedoc --excludePrivate --plugin typedoc-plugin-markdown --out docs/apidocs lib/index.ts",
49-
"release": "npm run build && npm publish --access public"
49+
"release": "npm run build && npm publish --provenance --access public"
5050
},
5151
"repository": {
5252
"type": "git",

0 commit comments

Comments
 (0)