-
Notifications
You must be signed in to change notification settings - Fork 20
56 lines (52 loc) · 1.33 KB
/
nodejs.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
name: NodeJS Continuous Health Check
on:
push:
branches: [ master ]
paths-ignore:
- "documentation/**"
- "README.md"
- "errors.log"
pull_request:
branches: [ master ]
paths-ignore:
- "documentation/**"
- "README.md"
- "errors.log"
jobs:
node_ci:
runs-on: ${{ matrix.os }}
env:
NODE_CACHE: "npm"
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
node: [18]
steps:
-
name: Check out repository
if: ${{ github.event_name == 'push' || github.event_name == 'pull_request' }}
uses: actions/checkout@v3
-
name: Setup node env
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
check-latest: false
registry-url: https://registry.npmjs.org
# cache: ${{ env.NODE_CACHE }}
# cache-dependency-path: ${{ matrix.dir }}/package-lock.json
-
name: Cleanup for node > 16
if: ${{ matrix.node!='16' }}
shell: bash -e -l {0}
run: |
sh wipe.sh keep-package-lock
npm i --no-audit
-
name: Build workspace
shell: bash -e -l {0}
run: |
npm ci --prefer-offline --no-audit
npm run --if-present build
npm run --if-present cilint