diff --git a/doc/source/conf.py b/doc/source/conf.py index 66f4f7d9..d2763e0b 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -15,9 +15,7 @@ from __future__ import unicode_literals import os -import subprocess import sys -import warnings import pbr.version @@ -40,7 +38,7 @@ sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), extensions = ['sphinx.ext.autodoc', 'sphinx.ext.coverage', 'sphinx.ext.intersphinx', - 'oslosphinx', + 'openstackdocstheme', 'ext.list_plugins', ] @@ -119,6 +117,7 @@ modindex_common_prefix = ['keystoneauth1.'] # Sphinx are currently 'default' and 'sphinxdoc'. #html_theme_path = ["."] #html_theme = '_theme' +html_theme = 'openstackdocs' # 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 @@ -151,13 +150,7 @@ modindex_common_prefix = ['keystoneauth1.'] # If not '', a 'Last updated on:' timestamp is inserted at every page bottom, # using the given strftime format. -git_cmd = ["git", "log", "--pretty=format:'%ad, commit %h'", "--date=local", - "-n1"] -try: - html_last_updated_fmt = subprocess.check_output(git_cmd).decode('utf-8') -except: - warnings.warn('Cannot get last updated time from git repository. ' - 'Not setting "html_last_updated_fmt".') +html_last_updated_fmt = '%Y-%m-%d %H:%M' # If true, SmartyPants will be used to convert quotes and dashes to # typographically correct entities. @@ -236,3 +229,8 @@ intersphinx_mapping = { 'osloconfig': ('https://docs.openstack.org/developer/oslo.config/', None), 'keystoneclient': (ksc, None), } + +# -- Options for openstackdocstheme ------------------------------------------- +repository_name = 'openstack/keystoneauth' +bug_project = 'keystoneauth' +bug_tag = 'doc' \ No newline at end of file diff --git a/releasenotes/source/conf.py b/releasenotes/source/conf.py index d54c6ad5..77cd260a 100644 --- a/releasenotes/source/conf.py +++ b/releasenotes/source/conf.py @@ -38,7 +38,7 @@ # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = [ - 'oslosphinx', + 'openstackdocstheme', 'reno.sphinxext', ] @@ -113,7 +113,7 @@ pygments_style = 'sphinx' # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. -html_theme = 'default' +html_theme = 'openstackdocs' # 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 @@ -152,6 +152,7 @@ html_static_path = ['_static'] # 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. @@ -278,3 +279,8 @@ texinfo_documents = [ # -- Options for Internationalization output ------------------------------ locale_dirs = ['locale/'] + +# -- Options for openstackdocstheme ------------------------------------------- +repository_name = 'openstack/keystoneauth' +bug_project = 'keystoneauth' +bug_tag = 'doc' diff --git a/test-requirements.txt b/test-requirements.txt index aae32369..e78b494b 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -10,7 +10,7 @@ coverage!=4.4,>=4.0 # Apache-2.0 fixtures>=3.0.0 # Apache-2.0/BSD mock>=2.0 # BSD oslo.config!=4.3.0,!=4.4.0,>=4.0.0 # Apache-2.0 -oslosphinx>=4.7.0 # Apache-2.0 +openstackdocstheme>=1.11.0 # Apache-2.0 oslo.utils>=3.20.0 # Apache-2.0 oslotest>=1.10.0 # Apache-2.0 os-testr>=0.8.0 # Apache-2.0