Skip to content

Commit

Permalink
ci: Use uv to generate docs in Read the Docs
Browse files Browse the repository at this point in the history
  • Loading branch information
attakei committed Feb 15, 2025
1 parent 544b72f commit f276d36
Showing 1 changed file with 9 additions and 16 deletions.
25 changes: 9 additions & 16 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,12 @@ build:
os: 'ubuntu-22.04'
tools:
python: '3.11'

# Build documentation in the doc/ directory with Sphinx
sphinx:
configuration: doc/conf.py
builder: dirhtml

# Optionally build your docs in additional formats such as PDF and ePub
formats: all

# Optionally set the version of Python and requirements required to build your docs
python:
install:
- method: pip
path: .
extra_requirements:
- doc
commands:
- pip install uv
- uv venv
- uv pip install '.[doc]'
- uv run --no-sync sphinx-build -b dirhtml doc $READTHEDOCS_OUTPUT/html
- uv run --no-sync sphinx-build -b html doc $READTHEDOCS_OUTPUT/epub
- uv run --no-sync sphinx-build -b latex doc $READTHEDOCS_OUTPUT/latex
- make -C $READTHEDOCS_OUTPUT/latex
- mv $READTHEDOCS_OUTPUT/latex/sphinx-revealjs.pdf $READTHEDOCS_OUTPUT/pdf/

0 comments on commit f276d36

Please sign in to comment.