Skip to content

Commit dd79088

Browse files
committed
fix: 改了一下CI流,现在全部部署在vercel上
1 parent dd2ceac commit dd79088

File tree

2 files changed

+10
-30
lines changed

2 files changed

+10
-30
lines changed

.github/workflows/deploy.yml

Lines changed: 7 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,11 @@
1-
name: Deploy to GitHub Pages
1+
name: Build Check
22

33
on:
44
push:
55
branches: [main]
6+
pull_request:
67
workflow_dispatch:
78

8-
permissions:
9-
contents: read
10-
pages: write
11-
id-token: write
12-
13-
concurrency:
14-
group: "pages"
15-
cancel-in-progress: true
16-
179
jobs:
1810
build:
1911
runs-on: ubuntu-latest
@@ -30,24 +22,10 @@ jobs:
3022
- uses: actions/setup-node@v4
3123
with:
3224
node-version: 20
33-
cache: "pnpm"
25+
cache: pnpm
3426

3527
- run: pnpm install --frozen-lockfile
36-
- run: pnpm run build # ← 只需要 build,静态站会输出到 ./out
37-
38-
# (可选)避免被 Jekyll 处理
39-
- run: touch ./out/.nojekyll
40-
41-
- uses: actions/upload-pages-artifact@v3
42-
with:
43-
path: ./out
44-
45-
deploy:
46-
needs: build
47-
runs-on: ubuntu-latest
48-
environment:
49-
name: github-pages
50-
url: ${{ steps.deployment.outputs.page_url }}
51-
steps:
52-
- id: deployment
53-
uses: actions/deploy-pages@v4
28+
- run: pnpm run lint
29+
- run: pnpm run lint:images
30+
- run: pnpm run typecheck
31+
- run: pnpm run build

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@
99
"postinstall": "fumadocs-mdx",
1010
"prepare": "husky",
1111
"lint:images": "node scripts/check-images.mjs",
12-
"migrate:images": "node scripts/move-doc-images.mjs"
12+
"migrate:images": "node scripts/move-doc-images.mjs",
13+
"lint": "next lint",
14+
"typecheck": "tsc --noEmit"
1315
},
1416
"dependencies": {
1517
"@giscus/react": "^3.1.0",

0 commit comments

Comments
 (0)