diff --git a/.github/workflows/build-deploy-to-gh-pages.yml b/.github/workflows/build-deploy-to-gh-pages.yml index 275ad8f..6acd782 100644 --- a/.github/workflows/build-deploy-to-gh-pages.yml +++ b/.github/workflows/build-deploy-to-gh-pages.yml @@ -6,11 +6,29 @@ on: - main jobs: - deploy: + build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: docuactions/github-pages@main - env: - DOCUACTIONS_TOKEN: ${{ secrets.GITHUB_TOKEN }} - DOCUACTIONS_DEPLOYMENT: ${{ secrets.DOCUACTIONS_DEPLOYMENT }} + - name: Checkout code + uses: actions/checkout@v3 + + - name: Install Node.js + uses: actions/setup-node@v3 + with: + node-version: '18' + + - name: Install dependencies + run: yarn + + - name: Build Docusaurus site + run: yarn build + + - name: Deploy + uses: peaceiris/actions-gh-pages@v4 + # If you're changing the branch from main, + # also change the `main` in `refs/heads/main` + # below accordingly. + if: github.ref == 'refs/heads/main' + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./build