diff --git a/docs_sphinx/conf.py b/docs_sphinx/conf.py index 86beea1b6..925a010d0 100644 --- a/docs_sphinx/conf.py +++ b/docs_sphinx/conf.py @@ -86,6 +86,14 @@ def __getattr__(cls, name): 'sphinx.ext.extlinks', 'sphinx_tabs.tabs'] +# Set readthedocs theme if available +try: + import sphinx_rtd_theme + extensions += ['sphinx_rtd_theme'] + html_theme = 'sphinx_rtd_theme' +except ImportError: + pass + # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] diff --git a/rtd-requirements.txt b/rtd-requirements.txt index 618a784bb..ccc25a2d3 100644 --- a/rtd-requirements.txt +++ b/rtd-requirements.txt @@ -8,3 +8,4 @@ sphinx==1.8.6 Jinja2<3.1.0 commonmark==0.9.1 recommonmark==0.5.0 +sphinx_rtd_theme