Reference the latest commit via hash #13
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: GitHub Pages | |
on: | |
push: | |
branches: | |
- master | |
paths: | |
- docs/** | |
- mkdocs.yml | |
workflow_call: | |
inputs: | |
hash: | |
description: 'Commit hash to fetch from' | |
required: false | |
default: '' | |
type: string | |
workflow_dispatch: | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: fkirc/skip-duplicate-actions@v5 | |
with: | |
cancel_others: 'true' | |
- uses: actions/checkout@v4 | |
with: | |
ref: ${{inputs.hash}} | |
fetch-depth: 0 # for the 'Last updated' timestamp | |
- name: Install requirements | |
run: pip install -r requirements.txt | |
- name: Build and deploy site | |
run: mkdocs gh-deploy --no-history |