Skip to content

Commit e07df86

Browse files
committed
ci: add release.yml
1 parent 6b3f4e8 commit e07df86

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

.github/workflows/release.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
jobs:
9+
release:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v3
13+
with:
14+
fetch-depth: 0
15+
submodules: true
16+
17+
- name: Install pnpm
18+
uses: pnpm/action-setup@v4
19+
20+
# after pnpm
21+
- name: Use Node.js LTS
22+
uses: actions/setup-node@v3
23+
with:
24+
node-version: 'lts/*'
25+
registry-url: https://registry.npmjs.org/
26+
cache: pnpm
27+
28+
- run: pnpm install
29+
30+
- run: pnpm run build
31+
# https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages
32+
- run: pnpm ci:publish
33+
env:
34+
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
35+
36+
- run: npx changelogithub
37+
env:
38+
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

0 commit comments

Comments
 (0)