File tree 4 files changed +9433
-13
lines changed
4 files changed +9433
-13
lines changed Original file line number Diff line number Diff line change @@ -13,28 +13,58 @@ jobs:
13
13
- 14
14
14
- 12
15
15
- 10
16
+
16
17
steps :
17
- - uses : actions/checkout@v2
18
- - uses : actions/setup-node@v1
18
+ - name : Checkout
19
+ uses : actions/checkout@v2
20
+
21
+ - name : Setup Node
22
+ uses : actions/setup-node@v1
19
23
with :
20
24
node-version : ${{ matrix.node-version }}
21
- - run : npm install
22
- - run : npm run build
23
- - run : npm run lint
24
- - run : nyc --silent npm run test
25
- - run : nyc report --reporter=text-lcov | coveralls
26
- - run : nyc check-coverage --lines 90
25
+
26
+ - name : Cache node modules
27
+ id : cache-node-modules
28
+ uses : actions/cache@v2
29
+ env :
30
+ cache-name : cache-node-modules
31
+ with :
32
+ path : node_modules
33
+ key : ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
34
+ restore-keys : |
35
+ ${{ runner.os }}-build-${{ env.cache-name }}-
36
+ ${{ runner.os }}-build-
37
+ ${{ runner.os }}-
38
+
39
+ - name : Install Dependencies
40
+ if : steps.cache-node-modules.outputs.cache-hit != 'true'
41
+ run : npm ci
42
+
43
+ - name : Build
44
+ run : npm run build
45
+
46
+ - name : Lint
47
+ run : npm run lint
48
+
49
+ - name : Test & Report
50
+ run : npm run nyc
51
+
52
+ - name : Upload to Coveralls
53
+ uses : coverallsapp/github-action@master
54
+ with :
55
+ github-token : ${{ secrets.GITHUB_TOKEN }}
27
56
release :
28
57
name : Release
29
58
needs : test
30
59
if : github.ref == 'refs/heads/master'
31
60
runs-on : ubuntu-latest
61
+
32
62
steps :
33
63
- uses : actions/checkout@v2
34
64
- uses : actions/setup-node@v1
35
65
with :
36
66
node-version : 10
37
- - run : npm install
67
+ - run : npm ci
38
68
- run : npm run build
39
69
- run : npx semantic-release
40
70
env :
Original file line number Diff line number Diff line change 1
1
node_modules
2
- package-lock.json
3
2
coverage
4
3
dist
5
4
src /generated
You can’t perform that action at this time.
0 commit comments