Merge pull request #180 from GuoXiCheng/dev-c #178
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 VuePress site | |
on: | |
push: | |
branches: | |
- master | |
- main | |
jobs: | |
build-and-deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@master | |
with: | |
fetch-depth: 0 | |
- name: Setup Node | |
uses: actions/setup-node@master | |
with: | |
node-version: '18.x' | |
- name: Install and Build | |
run: | | |
npm install | |
npm run docs:build | |
- name: Copy to deploy | |
run: | | |
cp src/CNAME src/.vuepress/dist/ | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: src/.vuepress/dist |