[rst] pypandoc

This commit is contained in:
mzwiessele 2015-11-07 11:24:17 +00:00
parent 6bba566f14
commit f4aa9e8d77
2 changed files with 5 additions and 5 deletions

View file

@ -16,5 +16,5 @@ recursive-include GPy *.so
recursive-include GPy *.pyx
# Testing
include GPy/testing/plotting_tests/baseline/.*.png
include GPy/testing/baseline/*.png
#include GPy/testing/pickle_test.pickle

View file

@ -49,9 +49,9 @@ def read_to_rst(fname):
try:
import pypandoc
rstname = "{}.{}".format(os.path.splitext(fname)[0], 'rst')
rststr = pypandoc.convert(read(fname), 'rst', format='md')
with open(rstname, 'w') as f:
f.write(rststr)
pypandoc.convert(read(fname), 'rst', format='md', outputfile=rstname)
with open(rstname, 'r') as f:
rststr = f.read()
return rststr
#return read(rstname)
except ImportError:
@ -137,7 +137,7 @@ setup(name = 'GPy',
include_package_data = True,
py_modules = ['GPy.__init__'],
test_suite = 'GPy.testing',
#long_description=read_to_rst('README.md'),
long_description=read_to_rst('README.md'),
install_requires=['numpy>=1.7', 'scipy>=0.16', 'six', 'paramz'],
extras_require = {'docs':['sphinx'],
'optional':['mpi4py',