Merge pull request #202 from tcbrindle/pr/versioning #495
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: Documentation | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@master | |
- name: Build documentation with Sphinx | |
uses: ammaraskar/sphinx-action@master | |
with: | |
build-command: "sphinx-build -b html . html" | |
docs-folder: 'docs/' | |
- name: Upload pages artifact | |
if: github.ref_name == 'main' | |
uses: actions/upload-pages-artifact@v1 | |
with: | |
path: docs/html/ | |
deploy: | |
if: github.ref_name == 'main' | |
needs: build | |
permissions: | |
pages: write | |
id-token: write | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Deploy to Github Pages | |
id: deployment | |
uses: actions/deploy-pages@v1 |