From 5ea0940b012085311ff8039deefb0b7f6208ca82 Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Sat, 30 May 2020 16:27:23 +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. Disable openstackdocs_auto_name to use 'project' variable as name. 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: I649b1b74cd8542bd5870938f3bc74e296df7a04e --- doc/requirements.txt | 6 +++--- doc/source/conf.py | 23 +++++------------------ releasenotes/source/conf.py | 13 ++++--------- 3 files changed, 12 insertions(+), 30 deletions(-) diff --git a/doc/requirements.txt b/doc/requirements.txt index ab2dc60..e2d3d65 100644 --- a/doc/requirements.txt +++ b/doc/requirements.txt @@ -2,8 +2,8 @@ # of appearance. Changing the order has an impact on the overall integration # process, which may cause wedges in the gate later. -openstackdocstheme>=1.30.0 # Apache-2.0 -sphinx>=1.8.0,!=2.1.0;python_version>='3.4' # BSD +openstackdocstheme>=2.2.1 # Apache-2.0 +sphinx>=2.0.0,!=2.1.0 # BSD sphinxcontrib-svg2pdfconverter>=0.1.0 # BSD -reno>=2.5.0 # Apache-2.0 +reno>=3.1.0 # Apache-2.0 diff --git a/doc/source/conf.py b/doc/source/conf.py index 5bb544d..691b01e 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -52,15 +52,6 @@ master_doc = 'index' project = u'cloudkitty-dashboard' copyright = u'2014, Objectif Libre' -# The version info for the project you're documenting, acts as replacement for -# |version| and |release|, also used in various other places throughout the -# built documents. -# -# The short X.Y version. -version = '0.1' -# The full version, including alpha/beta/rc tags. -release = '0.1' - # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. #language = None @@ -91,7 +82,7 @@ add_module_names = True #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 = [] @@ -141,11 +132,6 @@ html_theme = 'openstackdocs' # directly to the root of the documentation. #html_extra_path = [] -# If not '', a 'Last updated on:' timestamp is inserted at every page bottom, -# using the given strftime format. -#html_last_updated_fmt = '%b %d, %Y' -html_last_updated_fmt = '%Y-%m-%d %H:%M' - # If true, SmartyPants will be used to convert quotes and dashes to # typographically correct entities. #html_use_smartypants = True @@ -283,6 +269,7 @@ texinfo_documents = [ #texinfo_no_detailmenu = False # -- Options for openstackdocstheme ------------------------------------------- -repository_name = 'openstack/cloudkitty-dashboard' -bug_project = '891' -bug_tag = 'doc' +openstackdocs_repo_name = 'openstack/cloudkitty-dashboard' +openstackdocs_pdf_link = True +openstackdocs_auto_name = False +openstackdocs_use_storyboard = True diff --git a/releasenotes/source/conf.py b/releasenotes/source/conf.py index 16064e7..a6fa1e4 100644 --- a/releasenotes/source/conf.py +++ b/releasenotes/source/conf.py @@ -81,7 +81,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 = [] @@ -130,11 +130,6 @@ html_static_path = ['_static'] # directly to the root of the documentation. #html_extra_path = [] -# If not '', a 'Last updated on:' timestamp is inserted at every page bottom, -# using the given strftime format. -#html_last_updated_fmt = '%b %d, %Y' -html_last_updated_fmt = '%Y-%m-%d %H:%M' - # If true, SmartyPants will be used to convert quotes and dashes to # typographically correct entities. #html_use_smartypants = True @@ -257,9 +252,9 @@ texinfo_documents = [ #texinfo_no_detailmenu = False # -- Options for openstackdocstheme ------------------------------------------- -repository_name = 'openstack/cloudkitty-dashboard' -bug_project = '891' -bug_tag = 'doc' +openstackdocs_repo_name = 'openstack/cloudkitty-dashboard' +openstackdocs_auto_name = False +openstackdocs_use_storyboard = True # -- Options for Internationalization output ------------------------------ locale_dirs = ['locale/']