Skip to content

Commit

Permalink
add sphinx extensions to setup
Browse files Browse the repository at this point in the history
  • Loading branch information
boyska committed Aug 1, 2016
1 parent 4323ba3 commit 2b4e6c6
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
9 changes: 9 additions & 0 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,15 @@
'sphinx.ext.coverage',
'sphinx.ext.viewcode',
]
try:
import sphinxcontrib.autohttp.flask
except ImportError:
print "WARNING: sphinxcontrib-httpdomain not installed," \
"you will get no REST API doc"
print " You might want to do pip install -U pip && pip install '.[doc]'"
else:
del sphinxcontrib.autohttp.flask
extensions += ['sphinxcontrib.autohttp.flask']

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
Expand Down
3 changes: 3 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,9 @@ def read(fname):
'webant': ['translations/*/*/*.mo']
},
include_package_data=True,
extras_require={
'doc':['sphinx', 'sphinxcontrib-httpdomain>=1.1'],
},
tests_require=['nose', 'coverage'],
zip_safe=False,
cmdclass={'build': build,
Expand Down

0 comments on commit 2b4e6c6

Please sign in to comment.