reasonable error message for "beet help <unknown>"

This commit is contained in:
Adrian Sampson 2012-07-24 15:23:27 -07:00
parent ca1581996d
commit 82bcd63f34

View file

@ -660,6 +660,8 @@ class SubcommandsOptionParser(optparse.OptionParser):
# particular
cmdname = subargs[0]
helpcommand = self._subcommand_for_name(cmdname)
if not helpcommand:
self.error('no command named {0}'.format(cmdname))
helpcommand.parser.print_help()
self.exit()
else: