Mercurial > hg > simpypi
changeset 70:8fa30276b3e0
add a command line entry point
author | Jeff Hammel <jhammel@mozilla.com> |
---|---|
date | Fri, 02 Mar 2012 10:37:31 -0800 |
parents | 10f343c483ee |
children | dcb98ad8463e |
files | setup.py simpypi/factory.py |
diffstat | 2 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/setup.py Fri Mar 02 10:13:25 2012 -0800 +++ b/setup.py Fri Mar 02 10:37:31 2012 -0800 @@ -5,7 +5,7 @@ except IOError: description = '' -version = "0.0" +version = "0.1" setup(name='simpypi', version=version, @@ -26,5 +26,7 @@ ], entry_points=""" # -*- Entry points: -*- + [console_scripts] + simpypi = simpypi.factory:main """, )
--- a/simpypi/factory.py Fri Mar 02 10:13:25 2012 -0800 +++ b/simpypi/factory.py Fri Mar 02 10:37:31 2012 -0800 @@ -38,7 +38,7 @@ app = SimPyPI(**app_conf) return NamespacedFileserver(app, directory, '/index') -def main(args=sys.argv[:]): +def main(args=sys.argv[1:]): # parse command line options usage = '%prog [options]'