Switch from oslosphinx to openstackdocstheme

As part of the docs migration work[0] for Pike we need to switch to use the
openstackdocstheme.

[0] https://review.openstack.org/#/c/472275/

Change-Id: I9f5d44dfdfeeab87ced0936318d95741d62845ba
This commit is contained in:
Dong Ma 2017-06-25 01:08:57 +08:00
parent 2e1670c64f
commit 5dbb8c8c00
3 changed files with 19 additions and 12 deletions

View File

@ -1,8 +1,6 @@
import sys
import os
import openstackdocstheme
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
@ -18,9 +16,14 @@ import openstackdocstheme
extensions = ['sphinx.ext.autodoc',
'sphinx.ext.todo',
'sphinx.ext.viewcode',
'oslosphinx'
'openstackdocstheme'
]
# openstackdocstheme options
repository_name = 'openstack-infra/subunit2sql'
bug_project = 'subunit2sql'
bug_tag = ''
todo_include_todos = True
# Add any paths that contain templates here, relative to this directory.
@ -86,7 +89,7 @@ html_theme = 'openstackdocs'
#html_theme_options = {}
# Add any paths that contain custom themes here, relative to this directory.
html_theme_path = [openstackdocstheme.get_html_theme_path()]
#html_theme_path = []
# The name for this set of Sphinx documents. If None, it defaults to
# "<project> v<release> documentation".
@ -111,8 +114,7 @@ html_static_path = ['_static']
# 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"
html_last_updated_fmt = os.popen(git_cmd).read()
html_last_updated_fmt = '%Y-%m-%d %H:%M'
# If true, SmartyPants will be used to convert quotes and dashes to
# typographically correct entities.

View File

@ -26,10 +26,15 @@
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
'oslosphinx',
'reno.sphinxext',
'openstackdocstheme'
]
# openstackdocstheme options
repository_name = 'openstack-infra/subunit2sql'
bug_project = 'subunit2sql'
bug_tag = ''
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
@ -101,7 +106,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
@ -109,7 +114,7 @@ html_theme = 'default'
#html_theme_options = {}
# Add any paths that contain custom themes here, relative to this directory.
#html_theme_path = []
#html_theme_path = [openstackdocstheme.get_html_theme_path()]
# The name for this set of Sphinx documents. If None, it defaults to
# "<project> v<release> documentation".
@ -139,7 +144,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.

View File

@ -2,7 +2,7 @@ hacking>=0.12.0,!=0.13.0,<0.14
coverage>=3.6
fixtures>=0.3.14
mock>=1.0
sphinx>=1.1.2,<1.2
sphinx>=1.6.2 # BSD
testscenarios>=0.4
testrepository>=0.0.18
testtools>=0.9.34
@ -13,4 +13,4 @@ os-testr
oslo.concurrency>=3.5.0
# releasenotes
reno>=0.1.1 # Apache2
openstackdocstheme>=1.5.0 # Apache-2.0
openstackdocstheme>=1.11.0 # Apache-2.0