feat: 更新 GitHub Actions 工作流,简化部署步骤并添加 Netlify 部署支持
This commit is contained in:
11
.github/workflows/ci.yaml
vendored
11
.github/workflows/ci.yaml
vendored
@ -16,3 +16,14 @@ jobs:
|
|||||||
cp dist/index.html dist/200.html
|
cp dist/index.html dist/200.html
|
||||||
npx surge --project ./dist --domain $DEPLOY_DOMAIN --token d843de16b331c626f10771245c56ed93 # npx surge token
|
npx surge --project ./dist --domain $DEPLOY_DOMAIN --token d843de16b331c626f10771245c56ed93 # npx surge token
|
||||||
echo the preview URL is $DEPLOY_DOMAIN
|
echo the preview URL is $DEPLOY_DOMAIN
|
||||||
|
netlify:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: yanhao98/composite-actions/setup-node-environment@main
|
||||||
|
- name: deploy
|
||||||
|
run: |
|
||||||
|
npx vite build
|
||||||
|
npx netlify deploy --prod --dir dist
|
||||||
|
env:
|
||||||
|
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
|
||||||
|
NETLIFY_SITE_ID: 9273cadf-2b0a-4616-bbd6-b06a33646100
|
||||||
|
4
.github/workflows/test.yaml
vendored
4
.github/workflows/test.yaml
vendored
@ -6,6 +6,4 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: yanhao98/composite-actions/setup-node-environment@main
|
- uses: yanhao98/composite-actions/setup-node-environment@main
|
||||||
- name: deploy
|
- run: npx vue-tsc -b
|
||||||
run: |
|
|
||||||
npx vue-tsc -b
|
|
||||||
|
7991
pnpm-lock.yaml
generated
7991
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user