From b489995c8b04831f14e6ccec7eafcff52860e2ab Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Thu, 21 May 2020 16:11:46 +0200 Subject: [PATCH] Switch to newer openstackdocstheme and reno versions Switch to openstackdocstheme 2.2.1 and reno 3.1.0 versions. Using these versions will allow especially: * Linking from HTML to PDF document * Allow parallel building of documents * Fix some rendering problems Update Sphinx version as well. Set openstackdocs_pdf_link to link to PDF file. Note that the link to the published document only works on docs.openstack.org where the PDF file is placed in the top-level html directory. The site-preview places the PDF in a pdf directory. Change pygments_style to 'native' since old theme version always used 'native' and the theme now respects the setting and using 'sphinx' can lead to some strange rendering. openstackdocstheme renames some variables, so follow the renames before the next release removes them. A couple of variables are also not needed anymore, remove them. See also http://lists.openstack.org/pipermail/openstack-discuss/2020-May/014971.html Change-Id: Ib2fc9304a6db9f01eb6d0eb82363906fd322612f --- api-ref/source/conf.py | 8 ++++---- doc/source/conf.py | 9 +++++---- lower-constraints.txt | 6 +++--- releasenotes/source/conf.py | 8 ++++---- test-requirements.txt | 6 +++--- 5 files changed, 19 insertions(+), 18 deletions(-) diff --git a/api-ref/source/conf.py b/api-ref/source/conf.py index ccfa665d..3761696a 100644 --- a/api-ref/source/conf.py +++ b/api-ref/source/conf.py @@ -38,9 +38,9 @@ html_theme_options = { } # openstackdocstheme options -repository_name = 'openstack/blazar' -bug_project = 'blazar' -bug_tag = 'api-ref' +openstackdocs_repo_name = 'openstack/blazar' +openstackdocs_bug_project = 'blazar' +openstackdocs_bug_tag = 'api-ref' # -- General configuration ------------------------------------------------ @@ -73,7 +73,7 @@ language = None exclude_patterns = [] # The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'sphinx' +pygments_style = 'native' # If true, `todo` and `todoList` produce output, else they produce nothing. todo_include_todos = False diff --git a/doc/source/conf.py b/doc/source/conf.py index b9eaaf2d..a912457b 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -43,9 +43,10 @@ extensions = ['sphinx.ext.autodoc', ] # openstackdocstheme options -repository_name = 'openstack/blazar' -bug_project = 'blazar' -bug_tag = '' +openstackdocs_repo_name = 'openstack/blazar' +openstackdocs_pdf_link = True +openstackdocs_bug_project = 'blazar' +openstackdocs_bug_tag = '' wsme_protocols = ['restjson', 'restxml'] @@ -101,7 +102,7 @@ exclude_patterns = [ #show_authors = False # The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'sphinx' +pygments_style = 'native' # A list of ignored prefixes for module index sorting. #modindex_common_prefix = [] diff --git a/lower-constraints.txt b/lower-constraints.txt index b895a716..a3d6eac9 100644 --- a/lower-constraints.txt +++ b/lower-constraints.txt @@ -46,7 +46,7 @@ mox3==0.25.0 msgpack==0.5.6 netaddr==0.7.18 netifaces==0.10.6 -openstackdocstheme==1.31.2 +openstackdocstheme==2.2.1 os-api-ref==1.4.0 os-client-config==1.29.0 oslo.cache==1.29.0 @@ -85,7 +85,7 @@ python-novaclient==9.1.0 python-subunit==1.2.0 pytz==2018.3 PyYAML==3.12 -reno==2.5.0 +reno==3.1.0 repoze.lru==0.7 requests==2.18.4 requestsexceptions==1.4.0 @@ -96,7 +96,7 @@ simplegeneric==0.8.1 simplejson==3.13.2 six==1.10.0 snowballstemmer==1.2.1 -Sphinx==1.8.0 +Sphinx==2.0.0 sphinxcontrib-websupport==1.0.1 sqlalchemy-migrate==0.11.0 SQLAlchemy==1.0.10 diff --git a/releasenotes/source/conf.py b/releasenotes/source/conf.py index 15eb2cd6..3c5d62ba 100644 --- a/releasenotes/source/conf.py +++ b/releasenotes/source/conf.py @@ -41,9 +41,9 @@ extensions = [ ] # openstackdocstheme options -repository_name = 'openstack/blazar' -bug_project = 'blazar' -bug_tag = '' +openstackdocs_repo_name = 'openstack/blazar' +openstackdocs_bug_project = 'blazar' +openstackdocs_bug_tag = '' # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] @@ -96,7 +96,7 @@ exclude_patterns = [] # show_authors = False # The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'sphinx' +pygments_style = 'native' # A list of ignored prefixes for module index sorting. # modindex_common_prefix = [] diff --git a/test-requirements.txt b/test-requirements.txt index 07d65b6a..7dfe7869 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -13,7 +13,7 @@ oslotest>=3.2.0 # Apache-2.0 oslo.context>=2.19.2 # Apache-2.0 # Documentation -reno>=2.5.0 # Apache-2.0 -sphinx>=1.8.0,!=2.1.0 # BSD -openstackdocstheme>=1.31.2 # Apache-2.0 +reno>=3.1.0 # Apache-2.0 +sphinx>=2.0.0,!=2.1.0 # BSD +openstackdocstheme>=2.2.1 # Apache-2.0 os-api-ref>=1.4.0 # Apache-2.0