diff --git a/.github/workflows/gh-pages.yml b/.github/workflows/gh-pages.yml new file mode 100644 index 0000000..64f48a3 --- /dev/null +++ b/.github/workflows/gh-pages.yml @@ -0,0 +1,25 @@ +name: github pages + +on: + push: + branches: + - master # default branch + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + # 如果配置 themeConfig.lastUpdated 为 false,则不需要添加该参数以加快检出速度 + fetch-depth: 0 + - name: Install dependencies + run: npm install + - name: Build with dumi + run: npm run build + - name: Deploy + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./dist