Skip to content

Commit

Permalink
- update doc config
Browse files Browse the repository at this point in the history
  • Loading branch information
janbender committed Feb 21, 2024
1 parent 1b06319 commit 38c23dd
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 3 deletions.
35 changes: 35 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Read the Docs configuration file for Sphinx projects
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the OS, Python version and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.11"
# You can also specify other tool versions:
# nodejs: "20"
# rust: "1.70"
# golang: "1.20"

# Build documentation in the "docs/" directory with Sphinx
sphinx:
configuration: doc/conf.py
# You can configure Sphinx to use a different builder, for instance use the dirhtml builder for simpler URLs
# builder: "dirhtml"
# Fail on all warnings to avoid broken references
# fail_on_warning: true

# Optionally build your docs in additional formats such as PDF and ePub
# formats:
# - pdf
# - epub

# Optional but recommended, declare the Python requirements required
# to build your documentation
# See https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
python:
install:
- requirements: doc/requirements.txt
3 changes: 2 additions & 1 deletion doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
'recommonmark',
'sphinxcontrib.bibtex'
]
bibtex_bibfiles = ['bibliography.bib']

# Setup the breathe extension
breathe_projects = {
Expand Down Expand Up @@ -89,9 +90,9 @@
# on_rtd is whether we are on readthedocs.org, this line of code grabbed from docs.readthedocs.org
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'

html_theme = 'sphinx_rtd_theme'
if not on_rtd: # only import and set the theme if we're building docs locally
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]

# Add any paths that contain custom static files (such as style sheets) here,
Expand Down
5 changes: 3 additions & 2 deletions doc/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
exhale
recommonmark
sphinx==4.2.0
sphinxcontrib.bibtex < 2.0.0
Sphinx==5.2.3
sphinx_rtd_theme==1.3.0
sphinxcontrib.bibtex==2.6.1
docutils==0.16

0 comments on commit 38c23dd

Please sign in to comment.