switch to packaged sphinx theme

This commit is contained in:
David Lord 2016-11-03 23:01:10 -07:00
parent dcfdfc6476
commit 08d6de73a8
No known key found for this signature in database
GPG key ID: 7A1C87E3F5BC42A8
4 changed files with 4 additions and 100 deletions

View file

@ -19,7 +19,6 @@ import pkg_resources
# 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.
sys.path.append(os.path.join(os.path.dirname(__file__), '_themes'))
sys.path.append(os.path.dirname(__file__))
# -- General configuration -----------------------------------------------------
@ -110,7 +109,7 @@ exclude_patterns = ['_build']
# html_theme_options = {}
# Add any paths that contain custom themes here, relative to this directory.
html_theme_path = ['_themes']
# html_theme_path = ['_themes']
# The name for this set of Sphinx documents. If None, it defaults to
# "<project> v<release> documentation".
@ -263,19 +262,14 @@ intersphinx_mapping = {
}
try:
__import__('flask_theme_support')
pygments_style = 'flask_theme_support.FlaskyStyle'
__import__('flask_sphinx_themes')
html_theme = 'flask'
html_theme_options = {
'touch_icon': 'touch-icon.png'
}
except ImportError:
print('-' * 74)
print('Warning: Flask themes unavailable. Building with default theme')
print('If you want the Flask themes, run this command and build again:')
print()
print(' git submodule update --init')
print('-' * 74)
print('Flask theme unavailable; using the default theme.')
print('Install using `pip install Flask-Sphinx-Themes`.')
# unwrap decorators