Skip to content

Commit 18b6ec6

Browse files
authored
Merge pull request #15684 from Automattic/vkarpov15/gh-15680
ci: add publish script with provenance, with --dry-run for now
2 parents 104af11 + 044366f commit 18b6ec6

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

.github/workflows/publish.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Publish Package to npmjs
2+
3+
on:
4+
release:
5+
types: [published]
6+
workflow_dispatch: # 👈 allows you to trigger manually from the Actions tab
7+
8+
jobs:
9+
publish:
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: read
13+
id-token: write
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v4
17+
18+
- name: Setup Node.js
19+
uses: actions/setup-node@v4
20+
with:
21+
node-version: '24.x'
22+
registry-url: 'https://registry.npmjs.org'
23+
24+
- name: Install dependencies
25+
run: npm ci
26+
27+
- name: browser build
28+
run: npm run build-browser
29+
30+
- name: Dry run publish with provenance
31+
run: npm publish --provenance --access public

0 commit comments

Comments
 (0)