-
Notifications
You must be signed in to change notification settings - Fork 279
37 lines (30 loc) · 907 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
36
37
name: CI
on:
# CI is run on main because new branches can only access caches from master, not previous branches.
# So building on master allows new PR's to get the cache from before.
push:
branches: [main]
pull_request:
branches: [main]
jobs:
lint:
timeout-minutes: 5
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v3
- name: install node
uses: actions/setup-node@v3
with:
cache: "yarn"
node-version: "18"
- name: Restore cached dependencies for Node modules
id: module-cache
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/node_modules
key: ${{ runner.os }}--node--${{ hashFiles('**/yarn.lock') }}
- name: Install dependencies
run: yarn install
- name: Run prettier check
run: yarn lint:check