Skip to content

Commit d314d88

Browse files
🦌
1 parent ac25c68 commit d314d88

File tree

1 file changed

+36
-14
lines changed

1 file changed

+36
-14
lines changed

.github/workflows/build.yml

Lines changed: 36 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,44 @@
1-
name: Build
1+
name: CI
22

33
on: [push, pull_request]
44

55
jobs:
6-
Build:
6+
test:
7+
name: Test Node.js ${{ matrix.node-version }}
78
runs-on: ubuntu-latest
9+
strategy:
10+
fail-fast: true
11+
matrix:
12+
node-version:
13+
- 18
14+
- 22
15+
816
steps:
9-
- uses: actions/checkout@v3
17+
- name: Checkout
18+
uses: actions/checkout@v4
19+
20+
- name: Install pnpm
21+
uses: pnpm/action-setup@v3
22+
id: pnpm-install
23+
with:
24+
version: 9.12.2
25+
run_install: false
1026

11-
- uses: actions/setup-node@v3
27+
- name: Install Node.js
28+
uses: actions/setup-node@v4
1229
with:
13-
node-version: 16
14-
cache: yarn
15-
16-
- run: yarn install --frozen-lockfile
17-
- name: build
18-
# TODO Enable those lines below if you use a Redis cache, you'll also need to configure GitHub Repository Secrets
19-
# env:
20-
# REDIS_HOST: ${{ secrets.REDIS_HOST }}
21-
# REDIS_PASSWORD: ${{ secrets.REDIS_PASSWORD }}
22-
run: yarn build
30+
node-version: ${{ matrix.node-version }}
31+
cache: 'pnpm'
32+
33+
- name: Install dependencies
34+
run: pnpm install --frozen-lockfile --strict-peer-dependencies
35+
36+
- name: Run test
37+
run: pnpm test
38+
39+
# TODO Enable those lines below if you use a Redis cache, you'll also need to configure GitHub Repository Secrets
40+
# env:
41+
# REDIS_HOST: ${{ secrets.REDIS_HOST }}
42+
# REDIS_PASSWORD: ${{ secrets.REDIS_PASSWORD }}
43+
# - name: Build
44+
# run: pnpm build

0 commit comments

Comments
 (0)