Skip to content

Commit adaabff

Browse files
committed
chore: update GitHub Actions workflow to use Ubuntu 24.04 and improve caching
1 parent b4ee8ed commit adaabff

1 file changed

Lines changed: 35 additions & 12 deletions

File tree

.github/workflows/check.yaml

Lines changed: 35 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,30 @@ on:
44
push:
55
pull_request:
66

7+
permissions:
8+
contents: read
9+
10+
defaults:
11+
run:
12+
shell: bash --noprofile --norc -euo pipefail {0}
13+
714
jobs:
815
types:
9-
runs-on: ubuntu-latest
16+
runs-on: ubuntu-24.04
17+
timeout-minutes: 10
1018

1119
steps:
1220
- name: Checkout
13-
uses: actions/checkout@v6
21+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
22+
with:
23+
persist-credentials: false
1424

1525
- name: Setup Node.js
16-
uses: actions/setup-node@v6
26+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6
1727
with:
1828
node-version: 22
1929
cache: npm
30+
cache-dependency-path: package-lock.json
2031

2132
- name: Install dependencies
2233
run: npm ci
@@ -25,17 +36,21 @@ jobs:
2536
run: npm run types:check
2637

2738
typecheck:
28-
runs-on: ubuntu-latest
39+
runs-on: ubuntu-24.04
40+
timeout-minutes: 5
2941

3042
steps:
3143
- name: Checkout
32-
uses: actions/checkout@v6
44+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
45+
with:
46+
persist-credentials: false
3347

3448
- name: Setup Node.js
35-
uses: actions/setup-node@v6
49+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6
3650
with:
3751
node-version: 22
3852
cache: npm
53+
cache-dependency-path: package-lock.json
3954

4055
- name: Install dependencies
4156
run: npm ci
@@ -44,17 +59,21 @@ jobs:
4459
run: npm run typecheck
4560

4661
format:
47-
runs-on: ubuntu-latest
62+
runs-on: ubuntu-24.04
63+
timeout-minutes: 5
4864

4965
steps:
5066
- name: Checkout
51-
uses: actions/checkout@v6
67+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
68+
with:
69+
persist-credentials: false
5270

5371
- name: Setup Node.js
54-
uses: actions/setup-node@v6
72+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6
5573
with:
5674
node-version: 22
5775
cache: npm
76+
cache-dependency-path: package-lock.json
5877

5978
- name: Install dependencies
6079
run: npm ci
@@ -63,17 +82,21 @@ jobs:
6382
run: npm run format:check
6483

6584
test:
66-
runs-on: ubuntu-latest
85+
runs-on: ubuntu-24.04
86+
timeout-minutes: 10
6787

6888
steps:
6989
- name: Checkout
70-
uses: actions/checkout@v6
90+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
91+
with:
92+
persist-credentials: false
7193

7294
- name: Setup Node.js
73-
uses: actions/setup-node@v6
95+
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6
7496
with:
7597
node-version: 22
7698
cache: npm
99+
cache-dependency-path: package-lock.json
77100

78101
- name: Install dependencies
79102
run: npm ci

0 commit comments

Comments
 (0)