-
Notifications
You must be signed in to change notification settings - Fork 7
41 lines (37 loc) · 941 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
38
39
40
41
name: CI
on:
push:
branches:
- main
tags:
- '*'
pull_request: {}
jobs:
test:
timeout-minutes: 5
name: Tests
runs-on: ubuntu-latest
strategy:
matrix:
node: ['16', '18']
os: [ubuntu-latest, macOS-latest, windows-latest]
steps:
- uses: actions/checkout@v2
- uses: volta-cli/action@v1
with:
node-version: ${{ matrix.node }}
- uses: actions/cache@v2
id: yarn-cache
with:
path: '**/node_modules'
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: yarn --frozen-lockfile
if: steps.yarn-cache.outputs.cache-hit != 'true'
run: yarn --frozen-lockfile
- name: yarn prepare
if: steps.yarn-cache.outputs.cache-hit == 'true'
run: yarn prepare
- run: yarn lint
- run: yarn test