File tree Expand file tree Collapse file tree 3 files changed +76
-0
lines changed Expand file tree Collapse file tree 3 files changed +76
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Run basic linting and testing
2
+
3
+ on :
4
+ workflow_call :
5
+
6
+ jobs :
7
+ lint :
8
+ runs-on : ubuntu-latest
9
+ steps :
10
+ - uses : actions/checkout@v2
11
+ - uses : actions/setup-node@v3
12
+
13
+ - name : Install dev dependencies
14
+ run : yarn install
15
+
16
+ - name : ESLint
17
+ run : yarn run eslint
18
+
19
+ test :
20
+ needs : lint
21
+ strategy :
22
+ matrix :
23
+ version : [14, 16, 18]
24
+ runs-on : ubuntu-latest
25
+ steps :
26
+ - uses : actions/checkout@v2
27
+ - uses : actions/setup-node@v3
28
+ with :
29
+ node-version : ${{ matrix.version }}
30
+
31
+ - name : Install dev dependencies
32
+ run : yarn install
33
+
34
+ - name : Run tests
35
+ run : yarn run test
Original file line number Diff line number Diff line change
1
+ name : Pull request workflow
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - ' !master'
7
+ pull_request :
8
+
9
+ jobs :
10
+ lint :
11
+ uses : ./.github/workflows/lint.yaml
Original file line number Diff line number Diff line change
1
+ name : Release workflow
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+
8
+ jobs :
9
+ lint :
10
+ uses : ./.github/workflows/lint.yaml
11
+
12
+ release :
13
+ needs : lint
14
+ runs-on : ubuntu-latest
15
+ environment : production
16
+ steps :
17
+ - uses : actions/checkout@v2
18
+ - uses : actions/setup-node@v3
19
+ with :
20
+ node-version : ${{ matrix.version }}
21
+
22
+ - name : Install dev dependencies
23
+ run : yarn install
24
+
25
+ - name : Publish package using semantic-release
26
+ env :
27
+ NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
28
+ run : |
29
+ yarn build
30
+ yarn run semantic-release
You can’t perform that action at this time.
0 commit comments