From 787982ff23360efd2c3ebffa23611f5c8f938714 Mon Sep 17 00:00:00 2001 From: mrbean-bremen Date: Sun, 27 Nov 2016 21:32:55 +0100 Subject: [PATCH] Added README.md to pypi description - pypandoc needs to be installed during registration --- setup.py | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/setup.py b/setup.py index 1c1f4b68..d6142a1c 100644 --- a/setup.py +++ b/setup.py @@ -27,6 +27,15 @@ URL = "http://pyfakefs.org" +try: + import pypandoc + + LONG_DESCRIPTION = pypandoc.convert('README.md', 'rst') +except ImportError: + LONG_DESCRIPTION = '''Using pyfakefs, your tests operate on a fake file system in memory without +touching the real disk. The software under test requires no modification to work with pyfakefs.''' + + readme = os.path.join(os.path.dirname(__file__), 'README.md') LONG_DESCRIPTION = open(readme).read() @@ -70,9 +79,7 @@ maintainer=MAINTAINER, maintainer_email=MAINTAINER_EMAIL, description=DESCRIPTION, - long_description='''Using pyfakefs, your tests operate on a fake file system in memory without -touching the real disk. The software under test requires no modification to -work with pyfakefs.''', # LONG_DESCRIPTION, + long_description=LONG_DESCRIPTION, keywords=KEYWORDS, url=URL, classifiers=CLASSIFIERS,