Skip to content

Refactor Sphinx workflow to set up Python environment and install dep… #70

Refactor Sphinx workflow to set up Python environment and install dep…

Refactor Sphinx workflow to set up Python environment and install dep… #70

Workflow file for this run

name: Sphinx build
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install poetry
poetry install --with docs
- name: Build docs
run: |
cd docs
poetry run sphinx-build -b html . _build/html
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: html-docs
path: docs/_build/html/
- name: Deploy
uses: peaceiris/actions-gh-pages@v4
if: github.ref == 'refs/heads/main'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/_build/html