File tree Expand file tree Collapse file tree 1 file changed +6
-10
lines changed Expand file tree Collapse file tree 1 file changed +6
-10
lines changed Original file line number Diff line number Diff line change 2828 name : 部署文档站
2929 if : ${{ github.event_name != 'workflow_dispatch' || github.event.inputs.deploy_target == 'all' || github.event.inputs.deploy_target == 'docs' }}
3030 runs-on : ubuntu-latest
31- defaults :
32- run :
33- working-directory : docs
3431
3532 steps :
3633 - name : Checkout repository
4744 node-version : ' 16'
4845
4946 - name : Install dependencies
47+ working-directory : docs
5048 run : npm install
5149
5250 - name : Build documentation
51+ working-directory : docs
5352 run : npm run build
5453
5554 - name : Deploy to Vercel
@@ -58,16 +57,12 @@ jobs:
5857 vercel-token : ${{ secrets.VERCEL_TOKEN }}
5958 vercel-org-id : ${{ secrets.VERCEL_ORG_ID }}
6059 vercel-project-id : ${{ secrets.VERCEL_PROJECT_ID_DOCS }}
61- working-directory : docs
62- vercel-args : ${{ github.event_name == 'push' && '--prod' || '' }}
60+ vercel-args : ${{ github.event_name == 'push' && '--prod --cwd ./docs' || '--cwd ./docs' }}
6361
6462 deploy-examples :
6563 name : 部署示例项目
6664 if : ${{ github.event_name != 'workflow_dispatch' || github.event.inputs.deploy_target == 'all' || github.event.inputs.deploy_target == 'examples' }}
6765 runs-on : ubuntu-latest
68- defaults :
69- run :
70- working-directory : examples
7166
7267 steps :
7368 - name : Checkout code
7974 node-version : ' 16'
8075
8176 - name : Install dependencies
77+ working-directory : examples
8278 run : npm install
8379
8480 - name : Build
81+ working-directory : examples
8582 run : npm run build
8683
8784 - name : Deploy to Vercel
9087 vercel-token : ${{ secrets.VERCEL_TOKEN }}
9188 vercel-org-id : ${{ secrets.VERCEL_ORG_ID }}
9289 vercel-project-id : ${{ secrets.VERCEL_PROJECT_ID_EXAMPLES }}
93- working-directory : examples
94- vercel-args : ' --prod'
90+ vercel-args : ' --prod --cwd ./examples'
You can’t perform that action at this time.
0 commit comments