Created
June 16, 2020 13:52
-
-
Save nikto-b/0be11d0d001c11b5e89bc03501b66ace to your computer and use it in GitHub Desktop.
This file contains 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
from rich.console import Console | |
from rich.markdown import Markdown | |
if __name__ == "__main__": | |
if sys.argv[1:]: | |
console = Console() | |
with open(sys.argv[1:][0]) as readme: | |
markdown = Markdown(readme.read()) | |
console.print(markdown) | |
else: | |
print("Usage:\n\tmdprint README.md") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment