Commits

Dan Poirier committed 9613093

Add a version command

Comments (0)

Files changed (1)

wheel/tool/__init__.py

     convert_parser.add_argument('--verbose', '-v', action='store_true')
     convert_parser.set_defaults(func=convert_f)
 
+    def version_f(args):
+        from .. import __version__
+        print("wheel %s" % __version__)
+    version_parser = s.add_parser('version', help='Print version and exit')
+    version_parser.set_defaults(func=version_f)
+
     def help_f(args):
         p.print_help()
     help_parser = s.add_parser('help', help='Show this help')