-
-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (38 loc) · 1.06 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Release
on:
pull_request:
types:
- closed
jobs:
release:
runs-on: ubuntu-latest
if: ${{ github.event.pull_request.merged == true && contains(github.event.pull_request.labels.*.name, 'data') }}
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup pnpm
uses: pnpm/[email protected]
- name: Setup node
uses: actions/setup-node@v4
with:
node-version: 20.x
cache: pnpm
- name: Install and build
run: |
pnpm install
pnpm build
- name: Release
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git config user.email "[email protected]"
git config user.name "GitHub Actions"
pnpm config set //registry.npmjs.org/:_authToken $NPM_TOKEN
pnpm release:bgmd
- run: npx changelogithub
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}