-
Notifications
You must be signed in to change notification settings - Fork 325
41 lines (38 loc) · 959 Bytes
/
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
name: Build, Test, Lint, Format (Node.js)
on: [pull_request]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
node-version: [current, lts/*]
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: install latest npm
run: npm install -g npm@latest
- name: npm install
run: npm install
env:
CI: true
- name: npm run build --if-present
run: npm run build --if-present
env:
CI: true
- name: npm test
run: npm test
env:
CI: true
- name: npm run format:check
run: npm run format:check
env:
CI: true
NODE_ENV: test
- name: npm run lint
run: npm run lint
env:
CI: true