diff --git a/.github/workflows/deploy-book.yaml b/.github/workflows/deploy-book.yaml index 9520980..49980ce 100644 --- a/.github/workflows/deploy-book.yaml +++ b/.github/workflows/deploy-book.yaml @@ -36,6 +36,8 @@ jobs: run: shell: bash -l {0} steps: + - uses: actions/checkout@v4 + - name: Download merged artifact if: inputs.is_preview != 'true' uses: actions/download-artifact@v4 @@ -59,27 +61,33 @@ jobs: unzip book.zip rm -f book.zip + - name: Debug + run: pwd + + - name: Debug + run: ls -la book/_build/html + - name: Deploy to GitHub Pages uses: JamesIves/github-pages-deploy-action@v4 if: | (github.ref == 'refs/heads/main' && inputs.cname == 'None') with: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - BRANCH: gh-pages - FOLDER: ${{ inputs.publish_dir }} - CLEAN: true - KEEP_HISTORY: false - BASE_PATH: ${{ inputs.destination_dir }} + token: ${{ secrets.GITHUB_TOKEN }} + branch: gh-pages + folder: ${{ inputs.publish_dir }} + clean: true + clean-exclude: "preview" # keep existing previews from other PRs + target-folder: ${{ inputs.destination_dir }} - name: Deploy to GitHub Pages with custom domain uses: JamesIves/github-pages-deploy-action@v4 if: | (github.ref == 'refs/heads/main' && inputs.cname != 'None') with: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - BRANCH: gh-pages - FOLDER: ${{ inputs.publish_dir }} - CLEAN: true - KEEP_HISTORY: false - BASE_PATH: ${{ inputs.destination_dir }} - CNAME: ${{ inputs.cname }} + token: ${{ secrets.GITHUB_TOKEN }} + branch: gh-pages + folder: ${{ inputs.publish_dir }} + clean: true + clean-exclude: "preview" # keep existing previews from other PRs + target-folder: ${{ inputs.destination_dir }} + CNAME: ${{ inputs.cname }} # how can we set this for the new action?