Skip to content

Commit 8d6f184

Browse files
committed
chore: add CI workflow for continuous integration and validation
1 parent 92182d2 commit 8d6f184

1 file changed

Lines changed: 61 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- develop
8+
- "feat/**"
9+
- "fix/**"
10+
- "chore/**"
11+
pull_request:
12+
branches:
13+
- main
14+
- develop
15+
16+
permissions:
17+
contents: read
18+
19+
concurrency:
20+
group: ci-${{ github.workflow }}-${{ github.ref }}
21+
cancel-in-progress: true
22+
23+
jobs:
24+
validate:
25+
name: Validate (Node ${{ matrix.node-version }})
26+
runs-on: ubuntu-latest
27+
timeout-minutes: 20
28+
strategy:
29+
fail-fast: false
30+
matrix:
31+
node-version: ["20.x"]
32+
33+
steps:
34+
- name: Checkout
35+
uses: actions/checkout@v4
36+
37+
- name: Setup pnpm
38+
uses: pnpm/action-setup@v4
39+
with:
40+
run_install: false
41+
42+
- name: Setup Node.js
43+
uses: actions/setup-node@v4
44+
with:
45+
node-version: ${{ matrix.node-version }}
46+
cache: pnpm
47+
48+
- name: Install dependencies
49+
run: pnpm install --frozen-lockfile
50+
51+
- name: Type check
52+
run: pnpm exec tsc --noEmit
53+
54+
- name: Lint
55+
run: pnpm lint
56+
57+
- name: Test
58+
run: pnpm test -- --run
59+
60+
- name: Build
61+
run: pnpm build

0 commit comments

Comments
 (0)