-
Notifications
You must be signed in to change notification settings - Fork 144
59 lines (47 loc) · 1.28 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
50
51
52
53
54
55
56
57
58
59
name: Release
on:
push:
branches:
- main
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
node_version: [18, 20, 21, 22]
steps:
- uses: actions/checkout@v3
- name: Setup
uses: ./.github/actions/setup
with:
node_version: ${{ matrix.node_version }}
- name: Test
uses: ./.github/actions/test
with:
codecov_token: ${{ secrets.CODECOV_TOKEN }}
release:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
needs: [test]
steps:
- uses: actions/checkout@v3
- name: Setup
uses: ./.github/actions/setup
# - name: Build Headless Kit
# shell: bash
# run: npx nx build headless
# - name: Release
# uses: ./.github/actions/release
# with:
# github_token: ${{ secrets.GITHUB_TOKEN }}
# npm_token: ${{ secrets.NPM_TOKEN }}
- name: Create Release Pull Request or Publish
id: changesets
uses: changesets/action@v1
with:
version: pnpm changeset.version
publish: pnpm run release
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}