diff --git a/.github/workflows/site-deploy.yml b/.github/workflows/site-deploy.yml index f358c15171..6ab9f050fb 100644 --- a/.github/workflows/site-deploy.yml +++ b/.github/workflows/site-deploy.yml @@ -10,7 +10,7 @@ permissions: jobs: setup: runs-on: ubuntu-latest - if: github.event.ref_type == 'tag' && (contains(github.event.ref, '-') == false) + if: github.event.ref_type == 'tag' && (contains(github.event.ref, '-') == false || startsWith(github.event.ref, '4.')) steps: - name: checkout uses: actions/checkout@v3 @@ -66,5 +66,6 @@ jobs: - name: deploy uses: peaceiris/actions-gh-pages@v3 with: - deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }} + deploy_key: ${{ secrets.SITE_4X_DEPLOY_KEY }} + external_repository: ant-design/4x.ant.design publish_dir: ./_site diff --git a/package.json b/package.json index a9d1e1053a..5c43e379bd 100644 --- a/package.json +++ b/package.json @@ -64,7 +64,7 @@ "compile": "npm run clean && antd-tools run compile", "changelog": "node ./scripts/print-changelog", "predeploy": "antd-tools run clean && npm run site && cp CNAME _site && npm run site:test", - "deploy": "bisheng gh-pages --push-only --dotfiles", + "deploy": "gh-pages -d _site -r git@github.com:ant-design/4x.ant.design.git -b gh-pages", "deploy:china-mirror": "git checkout gh-pages && git pull origin gh-pages && git push git@gitee.com:ant-design/ant-design.git gh-pages", "dist": "antd-tools run dist", "dist:esbuild": "ESBUILD=true npm run dist",