forked from wangziqi/gongxue-base
feat: 更新 CI 工作流,优化依赖安装步骤
This commit is contained in:
@@ -17,7 +17,7 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
check:
|
check:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container: node:20.20.2-bookworm
|
container: node:22.22.0-bookworm
|
||||||
timeout-minutes: 30
|
timeout-minutes: 30
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@@ -28,18 +28,15 @@ jobs:
|
|||||||
fetch-depth: 1
|
fetch-depth: 1
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: npm ci
|
run: >-
|
||||||
|
npm ci
|
||||||
|
--workspace @gongxue/server
|
||||||
|
--omit=optional
|
||||||
|
--ignore-scripts
|
||||||
|
--no-audit
|
||||||
|
--no-fund
|
||||||
|
timeout-minutes: 5
|
||||||
|
|
||||||
- name: Lint
|
- name: Check server
|
||||||
run: |
|
run: npm run typecheck -w @gongxue/server
|
||||||
npm run lint -w @gongxue/admin
|
timeout-minutes: 5
|
||||||
npm run lint -w @gongxue/server -- --no-fix
|
|
||||||
|
|
||||||
- name: Type check
|
|
||||||
run: npm run typecheck
|
|
||||||
|
|
||||||
- name: Build frontend
|
|
||||||
run: npm run build -w @gongxue/admin
|
|
||||||
|
|
||||||
- name: Run backend tests
|
|
||||||
run: npm run test -w @gongxue/server -- --runInBand --forceExit
|
|
||||||
|
|||||||
Reference in New Issue
Block a user