From 68ae83e68c6f1f874c162c9bcf032bf305724bab Mon Sep 17 00:00:00 2001 From: Siddharth Bhat Date: Mon, 22 May 2017 13:36:15 +0000 Subject: [PATCH] [Docs] Use ReadTheDocs theme if available. Use ReadTheDocs theme for Sphinx if available since it is well maintained and used by readthedocs.org. Differential Revision: https://reviews.llvm.org/D33387 llvm-svn: 303550 --- polly/docs/conf.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/polly/docs/conf.py b/polly/docs/conf.py index 699cc7c..735a802 100644 --- a/polly/docs/conf.py +++ b/polly/docs/conf.py @@ -92,7 +92,13 @@ pygments_style = 'friendly' # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. -html_theme = 'haiku' +try: + import sphinx_rtd_theme + html_theme = "sphinx_rtd_theme" + html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] +except ModuleNotFoundError: + html_theme = 'haiku' + # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the -- 2.7.4