Skip to content

Commit 167fcfe

Browse files
chore: add npm publish workflow
1 parent bfa0050 commit 167fcfe

1 file changed

Lines changed: 35 additions & 0 deletions

File tree

.github/workflows/publish-npm.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Publish to npm
2+
3+
on:
4+
push:
5+
tags:
6+
- "*.*.*"
7+
workflow_dispatch:
8+
9+
jobs:
10+
publish:
11+
name: Build and Publish to npmjs.com
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout code (recursive submodules)
16+
uses: actions/checkout@v4
17+
with:
18+
submodules: recursive
19+
20+
- name: Setup Node.js
21+
uses: actions/setup-node@v4
22+
with:
23+
node-version: "24"
24+
registry-url: "https://registry.npmjs.org"
25+
26+
- name: Install dependencies
27+
run: npm ci
28+
29+
- name: Build everything
30+
run: npm run build:all
31+
32+
- name: Publish to npmjs.com
33+
run: npm publish --access public
34+
env:
35+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)