Created
April 15, 2019 10:56
-
-
Save RDCH106/bac494c14254e68d457a7185a09d9cac to your computer and use it in GitHub Desktop.
Script to convert Markdown (.md) to ReStructuredText (.rst)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
try: | |
import pypandoc | |
except ImportError: | |
print("pypandoc not available!!") | |
exit("First install pypandoc. Ex: \"pip install pypandoc\"") | |
long_description = pypandoc.convert('README.md', 'rst', outputfile='README.md2rst') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment