Skip to content

Commit 4f7b3d5

Browse files
authored
ci: add npm publish workflow (#10)
1 parent 8e18234 commit 4f7b3d5

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

.github/workflows/publish-npm.yaml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Publish package creator-model to npm
2+
3+
on:
4+
push:
5+
tags:
6+
- "v*"
7+
workflow_dispatch:
8+
9+
permissions:
10+
id-token: write
11+
contents: read
12+
13+
jobs:
14+
publish-package:
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- uses: actions/checkout@v4
19+
20+
- uses: oven-sh/setup-bun@v2
21+
with:
22+
bun-version: 1.2.2
23+
24+
- name: Install Dependencies
25+
run: bun install --frozen-lockfile
26+
27+
- name: Run Tests
28+
run: bun run test
29+
30+
- uses: actions/setup-node@v6
31+
with:
32+
node-version: "24.x"
33+
registry-url: "https://registry.npmjs.org"
34+
35+
- name: Publish to npm (Trusted)
36+
run: npm publish --access public

0 commit comments

Comments
 (0)