summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2017-07-07 16:56:15 +0000
committerGerrit Code Review <review@openstack.org>2017-07-07 16:56:15 +0000
commitc697e793af55634ade62bd278d67f49c4c33b4e5 (patch)
tree55ac3125e22fdf6fa60ec1bd8d660b7a48a0c944
parentb5bd8a86ca8d5c9ea01407054b1137616a804d07 (diff)
parent27296d58587a1a41535667d04b76c466ac404b53 (diff)
Merge "Switch from oslosphinx to openstackdocstheme"
-rw-r--r--doc/source/conf.py19
-rw-r--r--releasenotes/source/conf.py10
-rw-r--r--test-requirements.txt2
3 files changed, 17 insertions, 14 deletions
diff --git a/doc/source/conf.py b/doc/source/conf.py
index 2cfd7d4..0cef1f7 100644
--- a/doc/source/conf.py
+++ b/doc/source/conf.py
@@ -13,9 +13,7 @@
13from __future__ import unicode_literals 13from __future__ import unicode_literals
14 14
15import os 15import os
16import subprocess
17import sys 16import sys
18import warnings
19 17
20import pbr.version 18import pbr.version
21 19
@@ -43,7 +41,7 @@ extensions = ['sphinx.ext.autodoc',
43 'sphinx.ext.todo', 41 'sphinx.ext.todo',
44 'sphinx.ext.coverage', 42 'sphinx.ext.coverage',
45 'sphinx.ext.intersphinx', 43 'sphinx.ext.intersphinx',
46 'oslosphinx', 44 'openstackdocstheme',
47 'oslo_config.sphinxconfiggen' 45 'oslo_config.sphinxconfiggen'
48 ] 46 ]
49 47
@@ -126,6 +124,7 @@ modindex_common_prefix = ['keystonemiddleware.']
126# Sphinx are currently 'default' and 'sphinxdoc'. 124# Sphinx are currently 'default' and 'sphinxdoc'.
127#html_theme_path = ["."] 125#html_theme_path = ["."]
128#html_theme = '_theme' 126#html_theme = '_theme'
127html_theme = 'openstackdocs'
129 128
130# Theme options are theme-specific and customize the look and feel of a theme 129# Theme options are theme-specific and customize the look and feel of a theme
131# further. For a list of options available for each theme, see the 130# further. For a list of options available for each theme, see the
@@ -158,14 +157,7 @@ html_static_path = ['_static']
158 157
159# If not '', a 'Last updated on:' timestamp is inserted at every page bottom, 158# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
160# using the given strftime format. 159# using the given strftime format.
161git_cmd = ["git", "log", "--pretty=format:'%ad, commit %h'", "--date=local", 160html_last_updated_fmt = '%Y-%m-%d %H:%M'
162 "-n1"]
163try:
164 html_last_updated_fmt = subprocess.check_output(git_cmd).decode('utf-8')
165
166except Exception:
167 warnings.warn('Cannot get last updated time from git repository. '
168 'Not setting "html_last_updated_fmt".')
169 161
170# If true, SmartyPants will be used to convert quotes and dashes to 162# If true, SmartyPants will be used to convert quotes and dashes to
171# typographically correct entities. 163# typographically correct entities.
@@ -241,3 +233,8 @@ keystoneclient = 'https://docs.openstack.org/python-keystoneclient/latest/'
241 233
242intersphinx_mapping = {'keystoneclient': (keystoneclient, None), 234intersphinx_mapping = {'keystoneclient': (keystoneclient, None),
243 } 235 }
236
237# -- Options for openstackdocstheme -------------------------------------------
238repository_name = 'openstack/keystonemiddleware'
239bug_project = 'keystonemiddleware'
240bug_tag = ''
diff --git a/releasenotes/source/conf.py b/releasenotes/source/conf.py
index eab8c72..5043d3a 100644
--- a/releasenotes/source/conf.py
+++ b/releasenotes/source/conf.py
@@ -37,7 +37,7 @@
37# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom 37# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
38# ones. 38# ones.
39extensions = [ 39extensions = [
40 'oslosphinx', 40 'openstackdocstheme',
41 'reno.sphinxext', 41 'reno.sphinxext',
42] 42]
43 43
@@ -112,7 +112,7 @@ pygments_style = 'sphinx'
112 112
113# The theme to use for HTML and HTML Help pages. See the documentation for 113# The theme to use for HTML and HTML Help pages. See the documentation for
114# a list of builtin themes. 114# a list of builtin themes.
115html_theme = 'default' 115html_theme = 'openstackdocs'
116 116
117# Theme options are theme-specific and customize the look and feel of a theme 117# Theme options are theme-specific and customize the look and feel of a theme
118# further. For a list of options available for each theme, see the 118# further. For a list of options available for each theme, see the
@@ -151,6 +151,7 @@ html_static_path = ['_static']
151# If not '', a 'Last updated on:' timestamp is inserted at every page bottom, 151# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
152# using the given strftime format. 152# using the given strftime format.
153# html_last_updated_fmt = '%b %d, %Y' 153# html_last_updated_fmt = '%b %d, %Y'
154html_last_updated_fmt = '%Y-%m-%d %H:%M'
154 155
155# If true, SmartyPants will be used to convert quotes and dashes to 156# If true, SmartyPants will be used to convert quotes and dashes to
156# typographically correct entities. 157# typographically correct entities.
@@ -277,3 +278,8 @@ texinfo_documents = [
277 278
278# -- Options for Internationalization output ------------------------------ 279# -- Options for Internationalization output ------------------------------
279locale_dirs = ['locale/'] 280locale_dirs = ['locale/']
281
282# -- Options for openstackdocstheme -------------------------------------------
283repository_name = 'openstack/keystonemiddleware'
284bug_project = 'keystonemiddleware'
285bug_tag = ''
diff --git a/test-requirements.txt b/test-requirements.txt
index 208794b..f0a7384 100644
--- a/test-requirements.txt
+++ b/test-requirements.txt
@@ -10,7 +10,7 @@ cryptography>=1.6 # BSD/Apache-2.0
10docutils>=0.11 # OSI-Approved Open Source, Public Domain 10docutils>=0.11 # OSI-Approved Open Source, Public Domain
11fixtures>=3.0.0 # Apache-2.0/BSD 11fixtures>=3.0.0 # Apache-2.0/BSD
12mock>=2.0 # BSD 12mock>=2.0 # BSD
13oslosphinx>=4.7.0 # Apache-2.0 13openstackdocstheme>=1.11.0 # Apache-2.0
14oslotest>=1.10.0 # Apache-2.0 14oslotest>=1.10.0 # Apache-2.0
15reno!=2.3.1,>=1.8.0 # Apache-2.0 15reno!=2.3.1,>=1.8.0 # Apache-2.0
16requests-mock>=1.1 # Apache-2.0 16requests-mock>=1.1 # Apache-2.0