Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 18 additions & 18 deletions .github/workflows/deploy-book.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ on:
default: 'None' # This is just a flag for whether to ignore this input
type: string
publish_dir:
description: 'Publish dir for the peaceiris/actions-gh-pages action'
description: 'Publish dir for the action'
required: false
default: '_build/html'
type: string
Expand Down Expand Up @@ -60,26 +60,26 @@ jobs:
rm -f book.zip

- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4.0.0
uses: JamesIves/github-pages-deploy-action@v4
if: |
(github.ref == 'refs/heads/main'
&& inputs.cname == 'None')
(github.ref == 'refs/heads/main' && inputs.cname == 'None')
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ${{ inputs.publish_dir }}
enable_jekyll: false
keep_files: true # This preserves existing previews from open PRs
destination_dir: ${{ inputs.destination_dir }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH: gh-pages
FOLDER: ${{ inputs.publish_dir }}
CLEAN: true
KEEP_HISTORY: false
BASE_PATH: ${{ inputs.destination_dir }}

- name: Deploy to GitHub Pages with custom domain
uses: peaceiris/actions-gh-pages@v4.0.0
uses: JamesIves/github-pages-deploy-action@v4
if: |
(github.ref == 'refs/heads/main'
&& inputs.cname != 'None')
(github.ref == 'refs/heads/main' && inputs.cname != 'None')
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ${{ inputs.publish_dir }}
enable_jekyll: false
keep_files: true # This preserves existing previews from open PRs
destination_dir: ${{ inputs.destination_dir }}
cname: ${{ inputs.cname }}
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 }}