CI: allow releasing a new book version without a gtk-rs release
@@ -7,6 +7,7 @@ on:
- "master"
release:
types: [published]
+ workflow_dispatch:
jobs:
test:
@@ -47,11 +48,11 @@ jobs:
- run: mdbook build -d public
working-directory: book
- - run: echo "DEST=$(if [ "$GITHUB_EVENT_NAME" == "release" ]; then echo 'stable'; else echo 'git'; fi)" >> ${GITHUB_ENV}
+ - run: echo "DEST=$(if [ "$GITHUB_EVENT_NAME" == "release" || "$GITHUB_EVENT_NAME" == "workflow_dispatch" ]; then echo 'stable'; else echo 'git'; fi)" >> ${GITHUB_ENV}
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
- if: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master') || github.event_name == 'release' }}
+ if: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master') || github.event_name == 'release' || github.event_name == 'workflow_dispatch' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./book/public
