From a9484e1bc7291319c14a35adf7f277e826900af2 Mon Sep 17 00:00:00 2001 From: Yu-Jie Lin Date: Sun, 29 Jun 2014 12:39:35 +0800 Subject: fix install_test on missing Wheel package and argpare version option breaks CLI on Python --- CHANGES.rst | 3 +++ COPYING | 2 +- Makefile | 1 + smartypants | 7 ++++--- 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/CHANGES.rst b/CHANGES.rst index 66b642a..b3ac7e9 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -61,6 +61,9 @@ Development + add missing ``COPYING`` and ``CHANGES.rst`` to package (#3) + add ``bdist_wheel`` to the building process for Python Wheel format + add ``test_doc8`` target +* fix ``install_test`` on missing of Wheel package +* fix argparse version option breaks CLI on Python 3 + Release 1.8.3: 2013-11-08T03:03:43Z ----------------------------------- diff --git a/COPYING b/COPYING index b112a89..45e78a5 100644 --- a/COPYING +++ b/COPYING @@ -47,7 +47,7 @@ smartypants smartypants is a derivative work of SmartyPants. - Copyright (c) 2013 Yu-Jie Lin + Copyright (c) 2013, 2014 Yu-Jie Lin Copyright (c) 2004, 2005, 2007, 2013 Chad Miller Redistribution and use in source and binary forms, with or without diff --git a/Makefile b/Makefile index ff41868..1e366a0 100644 --- a/Makefile +++ b/Makefile @@ -73,6 +73,7 @@ $(VENV_PY2_CMD) $(VENV_PY3_CMD): rm -rf $(INSTALL_TEST_DIR) $@ $(INSTALL_TEST_DIR) ./setup.py sdist --dist-dir $(INSTALL_TEST_DIR) + $(INSTALL_TEST_DIR)/bin/pip install wheel $(INSTALL_TEST_DIR)/bin/pip install $(INSTALL_TEST_DIR)/*.tar.gz @\ CHK_VER="`$(PY2_CMD) $(SCRIPT) --version 2>&1`";\ diff --git a/smartypants b/smartypants index d6f2f7b..0b822df 100755 --- a/smartypants +++ b/smartypants @@ -1,5 +1,5 @@ #!/usr/bin/env python -# Copyright (c) 2013 Yu-Jie Lin +# Copyright (c) 2013, 2014 Yu-Jie Lin # Licensed under the BSD License, for detailed license information, see COPYING """ @@ -75,8 +75,9 @@ import smartypants def main(): - parser = argparse.ArgumentParser(description=smartypants.__description__, - version=smartypants.__version__) + parser = argparse.ArgumentParser(description=smartypants.__description__) + parser.add_argument('-v', '--version', action='version', + version=smartypants.__version__) parser.add_argument('-a', '--attr', default='1', help='processing attributes (Default: %(default)s)') parser.add_argument('-s', '--skip', -- cgit v1.2.1