chore: 将 CI 工作流从 Node.js 迁移到 Bun

This commit is contained in:
2026-04-23 14:34:09 +08:00
parent 1291910fb2
commit 414259cec6

View File

@@ -15,24 +15,18 @@ jobs:
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
uses: oven-sh/setup-bun@v2
with:
node-version: "24"
cache: "npm"
- name: Enable corepack and install npm
run: |
corepack enable
corepack prepare npm@latest --activate
bun-version: latest
- name: Install dependencies
run: npm install --frozen-lockfile
run: bun install
- name: Run ESLint
run: npm lint
run: bun run lint
- name: Run Prettier check
run: npm format:check
run: bun run format:check
format:
name: Auto-format (eslint --fix)
@@ -46,24 +40,18 @@ jobs:
persist-credentials: true
- name: Setup Node
uses: actions/setup-node@v4
uses: oven-sh/setup-bun@v2
with:
node-version: "24"
cache: "npm"
- name: Enable corepack and install npm
run: |
corepack enable
corepack prepare npm@latest --activate
bun-version: latest
- name: Install dependencies
run: npm install --frozen-lockfile
run: bun install
- name: Run Prettier --write
run: npm format
run: bun run format
- name: Run ESLint --fix
run: npm lint:fix
run: bun run lint:fix
- name: Commit & push fixes
run: |