feat: github settings

This commit is contained in:
Simon
2025-09-29 19:28:45 +08:00
parent 3beaa5c284
commit f04609300a
7 changed files with 209 additions and 0 deletions

34
.github/workflows/ci.yml vendored Normal file
View File

@@ -0,0 +1,34 @@
permissions:
contents: read
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20, 22]
steps:
- uses: actions/checkout@v5
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: Install dependencies
run: npm install
- name: Lint
run: npx eslint . && npx prettier --check **/*.ts
- name: Build
run: npm run build