summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrice Gauthier <patgauth@gmail.com>2012-05-14 15:43:42 -0400
committerPatrice Gauthier <patgauth@gmail.com>2012-05-14 15:43:42 -0400
commit132a6f08cf60ac518fd6e7ba91b8efd6a082af4d (patch)
treeaa7ef4d8cbe076b07834b70614e12bdb373352e0
parentcf38a177968d063fd81c989770f137e16cecc17b (diff)
downloaddisutils2-132a6f08cf60ac518fd6e7ba91b8efd6a082af4d.tar.gz
#13399 - some tweaking
-rw-r--r--distutils2/run.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/distutils2/run.py b/distutils2/run.py
index 1729761..133efc8 100644
--- a/distutils2/run.py
+++ b/distutils2/run.py
@@ -436,6 +436,7 @@ class Dispatcher(object):
# Pull the current command from the head of the command line
command = args[0]
if not command_re.match(command):
+ self.show_help()
raise SystemExit("invalid command name %r" % (command,))
self.commands.append(command)
@@ -537,7 +538,7 @@ class Dispatcher(object):
self._show_help(self.parser)
def exit_with_error_msg(self, msg):
- sys.exit('error: ' + msg.__str__())
+ sys.exit('error: %s ' % msg)
def print_usage(self, parser):
parser.set_option_table(global_options)