Skip to content

Commit 335b4fa

Browse files
authored
Standardise CI (#124)
1 parent 4f116f3 commit 335b4fa

1 file changed

Lines changed: 19 additions & 10 deletions

File tree

.github/workflows/ci.yml

Lines changed: 19 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
name: CI
2+
23
on:
3-
push:
4-
branches-ignore:
5-
- "master"
4+
pull_request:
5+
branches:
6+
- master
7+
8+
concurrency:
9+
group: ci-${{ github.workflow }}-${{ github.ref }}
10+
cancel-in-progress: true
611

712
env:
8-
node-version: "22"
13+
node-version: "22.x"
914

1015
jobs:
1116
test:
1217
name: Test
1318
runs-on: ubuntu-24.04
1419
steps:
15-
- name: Cancel Previous Runs
16-
uses: styfle/cancel-workflow-action@0.12.1
17-
with:
18-
access_token: ${{ github.token }}
19-
2020
- name: Check out repository
2121
uses: actions/checkout@v4
2222
with:
@@ -30,7 +30,16 @@ jobs:
3030
cache-dependency-path: "**/yarn.lock"
3131

3232
- name: Install deps
33-
run: yarn install --prefer-offline
33+
run: yarn install --prefer-offline --frozen-lockfile
34+
35+
- name: Cache node_modules
36+
uses: actions/cache@v4
37+
id: cache-node-modules
38+
with:
39+
path: node_modules
40+
key: node-modules-${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}
41+
restore-keys: |
42+
node-modules-${{ runner.os }}-
3443
3544
- name: Codegen & check
3645
run: ./bin/codegen-check.sh

0 commit comments

Comments
 (0)