Revive the UserError/UsageError distinction
authorW. Trevor King <wking@drexel.edu>
Mon, 2 May 2011 21:48:18 +0000 (17:48 -0400)
committerW. Trevor King <wking@drexel.edu>
Mon, 2 May 2011 21:48:24 +0000 (17:48 -0400)
commit1fcb1dd9114fba59a5d75570b9acc3b87d575821
treeaaed83677449589e1ef149a22d5bda1dac3ed9d8
parent741abdd7453d400049a089c22686af9000a91db5
Revive the UserError/UsageError distinction

UsageError was removed back in

  commit bf3d434b244c57556bec979acbc658c30eb58221
  Author: W. Trevor King <wking@drexel.edu>
  Date:   Sat Dec 12 00:31:55 2009 -0500

      Added libbe.command.base (with Command class)...

because the distinction between UsageError and UserError was unclear.
I've brought it back to satisfy a request by Christian Heinrich:

On Sun, May 01, 2011 at 02:52:13AM +0200, Christian Heinrich wrote:
> 3.) Using wrong syntax should receive better help messages.
>
> Current:
>
> "be new" -> ERROR:
> Missing required argument SUMMARY
>
> Should be:
>
> "be new" -> usage: be new [options] SUMMARY
> ...

He suggested we print the full option list as well, but I've decided
to just print the usage summary and remind the user how to get the
full help message if they want it.
libbe/command/__init__.py
libbe/command/base.py
libbe/ui/command_line.py