testing docs workflow #2
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: sphinx | |
on: | |
push: | |
branches: [master] | |
workflow_dispatch: | |
jobs: | |
build-docs: # Or you can rename this to 'docs' to be consistent with previous examples | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python 3.13 # Matching your project's Python version | |
uses: actions/setup-python@v5 | |
with: | |
python-version: "3.13" | |
- name: Install PIP | |
run: pip install --root-user-action=ignore --upgrade pip | |
- name: Install project dependencies for docs using pip # Use uv and dev dependencies | |
run: pip install sphinx furo | |
- name: Build Docs # Use your makefile to build docs | |
run: make docs # This will execute 'make docs' in your root directory | |
- name: Deploy to GitHub Pages # Using peaceiris/actions-gh-pages - a popular action | |
uses: peaceiris/actions-gh-pages@v3 | |
if: github.ref == 'refs/heads/master' | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./docs/_build/html # Correct path to Sphinx output directory |