From 033a4446c1522c9ff288afa6bc47c3d15d290216 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Thu, 25 Jun 2009 21:57:02 -0400 Subject: Updated help strings, man page, and completions --- be | 2 +- becommands/depend.py | 2 +- becommands/tag.py | 2 +- doc/be.1.sgml | 119 ++------------------------------------------------- libbe/cmdutil.py | 8 +++- 5 files changed, 13 insertions(+), 120 deletions(-) diff --git a/be b/be index fbe964f..ed1d7d7 100755 --- a/be +++ b/be @@ -27,7 +27,7 @@ if len(sys.argv) == 1 or sys.argv[1] in ('--help', '-h'): elif sys.argv[1] == '--complete': for command, module in cmdutil.iter_commands(): print command - print '\n'.join(["--help","--complete","--options"]) + print '\n'.join(["--help","--complete","--options","--version"]) elif sys.argv[1] == '--version': print _version.version_info["revision_id"] else: diff --git a/becommands/depend.py b/becommands/depend.py index 8dbb2eb..0e9ee97 100644 --- a/becommands/depend.py +++ b/becommands/depend.py @@ -13,7 +13,7 @@ # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -"""Add/remove bug dependencies.""" +"""Add/remove bug dependencies""" from libbe import cmdutil, bugdir import os, copy __desc__ = __doc__ diff --git a/becommands/tag.py b/becommands/tag.py index 5a18a7c..ab0324e 100644 --- a/becommands/tag.py +++ b/becommands/tag.py @@ -13,7 +13,7 @@ # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -"""Tag a bug, or search bugs for tags.""" +"""Tag a bug, or search bugs for tags""" from libbe import cmdutil, bugdir import os, copy __desc__ = __doc__ diff --git a/doc/be.1.sgml b/doc/be.1.sgml index 5e6efc3..a2df21f 100644 --- a/doc/be.1.sgml +++ b/doc/be.1.sgml @@ -18,7 +18,7 @@ be.1: be.1.sgml Ben"> Finney"> - 2008-04-21"> + 2009-06-25"> 1"> @@ -45,7 +45,7 @@ be.1: be.1.sgml &dhsurname; - 2008 + 2009 &dhusername; &dhdate; @@ -88,125 +88,12 @@ be.1: be.1.sgml COMMANDS - - - assign - - - Assign an individual or group to fix a bug - - - - - close - - - Close a bug - - - - - comment - - - Add a comment to a bug - - - - - diff - - - Compare bug reports with older tree - - - help - Print help for given subcommand - - - - - inprogress - - - Bug fixing in progress - - - - - list - - - List bugs - - - - - new - - - Create a new bug - - - - - open - - - Re-open a bug - - - - - set - - - Change tree settings - - - - - set-root - - - Assign the root directory for bug tracking - - - - - severity - - - Show or change a bug's severity level - - - - - show - - - Show a particular bug - - - - - target - - - Show or change a bug's target for fixing - - - - - upgrade - - - Upgrade the bugs to the latest format + Print help for be and a list of all available commands. diff --git a/libbe/cmdutil.py b/libbe/cmdutil.py index 6be7540..5873607 100644 --- a/libbe/cmdutil.py +++ b/libbe/cmdutil.py @@ -79,11 +79,17 @@ def help(cmd=None): for name, module in iter_commands(): cmdlist.append((name, module.__desc__)) longest_cmd_len = max([len(name) for name,desc in cmdlist]) - ret = ["Bugs Everywhere - Distributed bug tracking\n", + ret = ["Bugs Everywhere - Distributed bug tracking", + "", + "usage: be [command] [command_options ...] [command_args ...]", + "or: be help", + "or: be help [command]", + "", "Supported commands"] for name, desc in cmdlist: numExtraSpaces = longest_cmd_len-len(name) ret.append("be %s%*s %s" % (name, numExtraSpaces, "", desc)) + return "\n".join(ret) def completions(cmd): -- cgit