Skip to content

Commit d842f86

Browse files
committed
chore(ci): github action config
1 parent 29bb923 commit d842f86

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

.github/workflows/main.yml

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# This is a basic workflow to help you get started with Actions
2+
3+
name: test & lint
4+
5+
on:
6+
push:
7+
branches:
8+
- "main"
9+
- "dev"
10+
pull_request:
11+
branches:
12+
- "main"
13+
- "dev"
14+
15+
jobs:
16+
build:
17+
runs-on: ubuntu-latest
18+
19+
strategy:
20+
matrix:
21+
node-version: [14.x, 16.x, 18.x]
22+
23+
steps:
24+
- uses: actions/checkout@v3
25+
26+
- name: Use Node.js ${{ matrix.node-version }}
27+
uses: actions/setup-node@v3
28+
with:
29+
node-version: ${{ matrix.node-version }}
30+
31+
- name: create package-lock.json
32+
run: npm i --package-lock-only --ignore-scripts
33+
34+
- run: npm ci
35+
36+
- name: Run lint
37+
run: npm run lint
38+
39+
- name: Run test
40+
run: npm run test:coverage

0 commit comments

Comments
 (0)