Skip to content

Project setup

Project setup #6

Workflow file for this run

name: Documentation
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python and dependencies
uses: ./.github/actions/python-deps
with:
pythonVersion: "3.11"
- name: Build documentation
run: mkdocs build
- name: Archive built documentation
uses: actions/upload-artifact@v4
with:
name: docs
path: public/docs
deploy-docs:
runs-on: ubuntu-latest
name: Deploy documentation to GitHub Pages
# publish on 'main' only to prevent version clutter
if: ${{ github.ref == 'refs/heads/main' }}
steps:
- uses: actions/checkout@v4
- name: Set up Python and dependencies
uses: ./.github/actions/python-deps
with:
pythonVersion: "3.11"
- name: Restore built docs from artifacts
uses: actions/download-artifact@v4
with:
name: backend_docker
path: public/docs
- name: Publish documentation
uses: ./.github/actions/mike-docs
with:
version: ${{ github.event.release.tag_name }}
alias: latest