diff options
| -rw-r--r-- | NEWS | 5 | ||||
| -rw-r--r-- | mammoth/cli.py (renamed from scripts/mammoth) | 5 | ||||
| -rw-r--r-- | setup.py | 6 |
3 files changed, 12 insertions, 4 deletions
@@ -1,3 +1,8 @@ +# 1.0.1 + +* Improve script installation on Windows by using entry_points instead of + scripts in setup.py. + # 1.0.0 * Remove deprecated convert_underline argument. diff --git a/scripts/mammoth b/mammoth/cli.py index 1194540..8161a3f 100644 --- a/scripts/mammoth +++ b/mammoth/cli.py @@ -1,5 +1,3 @@ -#!/usr/bin/env python - import argparse import contextlib import sys @@ -7,7 +5,7 @@ import os import shutil import mammoth -from mammoth import writers +from . import writers def main(): @@ -114,3 +112,4 @@ def _parse_args(): if __name__ == "__main__": main() + @@ -25,7 +25,11 @@ setup( author_email='mike@zwobble.org', url='http://github.com/mwilliamson/python-mammoth', packages=['mammoth', 'mammoth.docx', 'mammoth.html', 'mammoth.style_reader', 'mammoth.writers'], - scripts=["scripts/mammoth"], + entry_points={ + "console_scripts": [ + "mammoth=mammoth.cli:main" + ] + }, keywords="docx word office clean html markdown md", install_requires=_install_requires, classifiers=[ |
