import os
import sys
import pkg_resources
extensions = [
'sphinx.ext.autodoc',
'sphinx.ext.intersphinx',
'sphinx.ext.viewcode',
]
templates_path = ['_templates']
source_suffix = '.rst'
master_doc = 'index'
project = 'atomicwrites'
copyright = '2015, Markus Unterwaditzer'
try:
release = pkg_resources.require('atomicwrites')[0].version
except pkg_resources.DistributionNotFound:
print('To build the documentation, the distribution information of '
'atomicwrites has to be available. Run "setup.py develop" to do '
'this.')
sys.exit(1)
version = '.'.join(release.split('.')[:2])
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
try:
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
except ImportError:
html_theme = 'default'
if not on_rtd:
print('-' * 74)
print('Warning: sphinx-rtd-theme not installed, building with default '
'theme.')
print('-' * 74)
exclude_patterns = ['_build']
pygments_style = 'sphinx'
html_static_path = ['_static']
htmlhelp_basename = 'atomicwritesdoc'
latex_elements = {}
latex_documents = [
('index', 'atomicwrites.tex', 'atomicwrites Documentation',
'Markus Unterwaditzer', 'manual'),
]
man_pages = [
('index', 'atomicwrites', 'atomicwrites Documentation',
['Markus Unterwaditzer'], 1)
]
texinfo_documents = [
('index', 'atomicwrites', 'atomicwrites Documentation',
'Markus Unterwaditzer', 'atomicwrites', 'One line description of project.',
'Miscellaneous'),
]
epub_title = 'atomicwrites'
epub_author = 'Markus Unterwaditzer'
epub_publisher = 'Markus Unterwaditzer'
epub_copyright = '2015, Markus Unterwaditzer'
epub_exclude_files = ['search.html']
intersphinx_mapping = {'http://docs.python.org/': None}