File tree Expand file tree Collapse file tree 2 files changed +51
-1
lines changed
Expand file tree Collapse file tree 2 files changed +51
-1
lines changed Original file line number Diff line number Diff line change 1+ name : Publish NPM Packages
2+
3+ on :
4+ release :
5+ types : [published] # triggers when a release is published on GitHub
6+ workflow_dispatch : # allows manual trigger from the Actions tab
7+
8+ jobs :
9+ publish :
10+ name : Build, Test & Publish to NPM
11+ runs-on : ubuntu-latest
12+ defaults :
13+ run :
14+ working-directory : platform/packages
15+
16+ permissions :
17+ contents : read
18+ id-token : write # required for npm provenance
19+
20+ steps :
21+ - name : Checkout repository
22+ uses : actions/checkout@v4
23+
24+ - name : Setup pnpm
25+ uses : pnpm/action-setup@v4
26+ with :
27+ run_install : false
28+
29+ - name : Setup Node.js
30+ uses : actions/setup-node@v4
31+ with :
32+ node-version : ' 24'
33+ registry-url : ' https://registry.npmjs.org'
34+ cache : ' pnpm'
35+ cache-dependency-path : framework/platform/packages/pnpm-lock.yaml
36+
37+ - name : Install dependencies
38+ run : pnpm install --frozen-lockfile
39+
40+ - name : Build all packages
41+ run : pnpm build
42+
43+ - name : Run tests
44+ run : pnpm test
45+
46+ - name : Publish all packages to NPM
47+ run : pnpm -r publish --access public --no-git-checks
48+ env :
49+ NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
50+
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ name: Release and Deploy
66
77on :
88 release :
9- types : [ created ]
9+ types : [ published ]
1010
1111jobs :
1212 build :
You can’t perform that action at this time.
0 commit comments