fix(deploy): use npm@20 to fix error #676
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy | |
on: | |
workflow_dispatch: | |
pull_request: | |
branches: | |
- v5 | |
push: | |
branches: | |
- v5 | |
jobs: | |
deploy-site: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- run: npm install | |
- run: cd site && npm install | |
- run: cd site && npm run build | |
- run: cp ./site/CNAME ./site/dist/CNAME | |
- run: | | |
cd site/dist | |
git init | |
git config --local user.name antv | |
git config --local user.email antv@antfin.com | |
git add . | |
git commit -m "update by release action" | |
- uses: ad-m/github-push-action@master | |
with: | |
github_token: ${{secrets.PERSONAL_ACCESS_TOKEN}} | |
directory: site/dist | |
branch: gh-pages | |
force: true |