hookmeup

A Git hook to automate your Pipenv and Django workflow
git clone git://git.danielmoch.com/hookmeup.git
Log | Files | Refs | README | LICENSE

commit 4ea727b23fd94f2dffe812abe43d64ee92325f79
parent 68315a92bc80d9dd06874bde82c9a93703b259a9
Author: Daniel Moch <daniel@danielmoch.com>
Date:   Mon, 20 Aug 2018 22:24:24 -0400

Refactor __init__.py

Diffstat:
Mhookmeup/__init__.py | 13++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)

diff --git a/hookmeup/__init__.py b/hookmeup/__init__.py @@ -6,24 +6,27 @@ from . import hookmeup __author__ = 'Daniel Moch' -__email__ = 'daniel@danielmoch.com' __version__ = '0.1.0' -__copyright__ = 'Copyright (c) 2018, Daniel Moch' def main(): """Main hookmeup entrypoint""" parser = argparse.ArgumentParser() - parser.add_argument('-v', action='version', version='%(prog)s 0.1.0') + parser.add_argument( + '-v', action='version', + version='%(prog)s {}'.format(__version__)) subparsers = parser.add_subparsers( title='subcommands', description='Valid %(prog)s subcommands') install_parser = subparsers.add_parser( 'install', - description='Install hook into repository') + description='Run inside a repository to install the hook. \ + Fails if the current directory is not inside a Git \ + repository.') install_parser.set_defaults(func=hookmeup.install) post_commit_parser = subparsers.add_parser( 'post-checkout', - description='Run post-checkout hook') + description='Run post-checkout hook. This should normally \ + be called by Git automatically.') post_commit_parser.add_argument('old', help='the old commit') post_commit_parser.add_argument('new', help='the new commit') post_commit_parser.add_argument(