Skip to content

Commit 75ba39d

Browse files
committed
优化GitHub Actions工作流:使用Node.js 20,添加调试信息并启用legacy-peer-deps
1 parent 2281dcc commit 75ba39d

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

.github/workflows/deploy.yml

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,27 @@ jobs:
1616
steps:
1717
- name: Checkout 🛎️
1818
uses: actions/checkout@v3
19+
with:
20+
fetch-depth: 0
1921

2022
- name: Setup Node.js
2123
uses: actions/setup-node@v3
2224
with:
23-
node-version: '18'
25+
node-version: '20' # 使用更新的Node.js版本
2426
cache: 'npm'
27+
28+
- name: Debug Environment
29+
run: |
30+
node --version
31+
npm --version
32+
ls -la
2533
2634
- name: Install dependencies
27-
run: npm install
35+
run: |
36+
npm config set legacy-peer-deps true
37+
npm install --no-fund --no-audit --prefer-offline
38+
env:
39+
CI: true
2840

2941
- name: Build
3042
run: npm run build

0 commit comments

Comments
 (0)