File tree Expand file tree Collapse file tree 2 files changed +45
-53
lines changed Expand file tree Collapse file tree 2 files changed +45
-53
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -2,12 +2,13 @@ name: release-please
22
33on :
44 push :
5- branches : [main] # updates/opens the release PR when commits land on main via merges
5+ branches : [main] # updates/opens the release PR when commits land on main
66 workflow_dispatch :
77
88permissions :
99 contents : write
1010 pull-requests : write
11+ id-token : write
1112
1213concurrency :
1314 group : release-please
@@ -16,7 +17,49 @@ concurrency:
1617jobs :
1718 release-please :
1819 runs-on : ubuntu-latest
20+ outputs :
21+ release_created : ${{ steps.rp.outputs.release_created }}
1922 steps :
20- - uses : googleapis/release-please-action@v4
23+ - id : rp
24+ uses : googleapis/release-please-action@v4
2125 with :
2226 config-file : release-please-config.json
27+
28+ publish :
29+ needs : release-please
30+ if : needs.release-please.outputs.release_created == 'true'
31+ runs-on : ubuntu-latest
32+ steps :
33+ - uses : actions/checkout@v4
34+
35+ - uses : pnpm/action-setup@v4
36+ with :
37+ version : 9
38+
39+ - uses : actions/setup-node@v4
40+ with :
41+ node-version : " 20"
42+ cache : " pnpm"
43+ registry-url : " https://registry.npmjs.org"
44+
45+ - run : npm install -g npm@latest
46+
47+ - run : pnpm install --frozen-lockfile
48+
49+ - run : pnpm build
50+
51+ - run : pnpm -s vitest run --reporter=dot
52+ env :
53+ CI : true
54+
55+ - name : publish to npm
56+ run : |
57+ VERSION=$(node -p "require('./package.json').version")
58+ if [[ "$VERSION" == *-* ]]; then
59+ npm publish --access public --provenance --tag next
60+ else
61+ npm publish --access public --provenance
62+ fi
63+
64+ - name : publish to JSR
65+ run : pnpm dlx jsr publish
You can’t perform that action at this time.
0 commit comments