File tree Expand file tree Collapse file tree 1 file changed +2
-40
lines changed Expand file tree Collapse file tree 1 file changed +2
-40
lines changed Original file line number Diff line number Diff line change 4
4
push :
5
5
branches :
6
6
- main
7
- workflow_dispatch :
8
7
9
8
concurrency : ${{ github.workflow }}-${{ github.ref }}
10
9
11
10
jobs :
12
- version :
13
- name : Release
14
- runs-on : ubuntu-latest
15
- steps :
16
- - name : Checkout Repo
17
- uses : actions/checkout@v3
18
- with :
19
- fetch-depth : 0
20
-
21
- - name : Setup Node.js
22
- uses : actions/setup-node@v3
23
- with :
24
- cache : yarn
25
- node-version : lts/*
26
-
27
- - name : Install Dependencies
28
- run : yarn
29
-
30
- - name : Create Release Pull Request or Publish to npm
31
- id : changesets
32
- uses : changesets/action@v1
33
- with :
34
- version : yarn version
35
- env :
36
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
37
-
38
11
release :
39
12
name : Release
40
13
runs-on : ubuntu-latest
41
- if : ${{ github.ref == 'refs/heads/main' }}
42
- needs : [version]
43
14
steps :
44
15
- name : Checkout Repo
45
16
uses : actions/checkout@v3
46
- with :
47
- fetch-depth : 0
48
17
49
- - name : Setup Node.js
18
+ - name : Setup Node.js
50
19
uses : actions/setup-node@v3
51
20
with :
52
- cache : yarn
53
21
node-version : lts/*
54
22
55
23
- name : Install Dependencies
56
24
run : yarn
57
25
58
- - name : Create Release Pull Request or Publish to npm
59
- id : changesets
26
+ - name : Create Release Pull Request
60
27
uses : changesets/action@v1
61
- with :
62
- version : yarn version
63
- publish : yarn release
64
28
env :
65
- NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
66
29
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
67
- NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
You can’t perform that action at this time.
0 commit comments