-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (38 loc) · 909 Bytes
/
build.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
name: Build
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
jobs:
build_and_test:
name: Build and test
runs-on: ${{ matrix.config.os }}
strategy:
matrix:
config:
- os: ubuntu-20.04
- os: macos-11
- os: windows-2022
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4.0.2
with:
node-version-file: '.nvmrc'
- name: Install dependencies
run: npm ci
- name: Lint
run: npm run lint:check
- name: Format
run: npm run format:check
- name: Test
run: xvfb-run -a npm test
if: runner.os == 'Linux'
- name: Test
run: npm test
if: runner.os != 'Linux'
- name: Build
run: npm run compile