-
Notifications
You must be signed in to change notification settings - Fork 0
35 lines (31 loc) · 822 Bytes
/
ci.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
name: CI
on:
pull_request:
branches: [main]
push:
branches: [main]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version-file: ./.node-version
- uses: actions/cache@v3
id: node_modules_cache_id
env:
cache-name: cache-node-modules
with:
path: node_modules
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
- if: ${{ steps.node_modules_cache_id.outputs.cache-hit != 'true' }}
run: npm ci
- name: ESLint
run: npm run lint
- name: Prettier
run: npm run format
- name: Test
run: npm run test
- name: Type Check
run: npm run type-check