Bug 31772

Summary: 'bugzilla-tool help' should only show common commands like how 'git help' does
Product: WebKit Reporter: Eric Seidel (no email) <eric>
Component: Tools / TestsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: OS X 10.5   
Bug Depends on: 31771    
Bug Blocks:    
Attachments:
Description Flags
Add help command abarth: review+, abarth: commit-queue-

Description Eric Seidel (no email) 2009-11-21 12:48:40 PST
'bugzilla-tool help' should only show common commands like how 'git help' does

We're adding more and more commands to bugzilla-tool to support the style queues and personal workflows.  We don't need to show these to every user, as they would likely find them overwhelming.  We need to add a flag to Command to mark it as a "common" command to be shown in the primary help.

Examples of commands which we would not mark as "common":
commit-queue
style-queue
build
Comment 1 Eric Seidel (no email) 2009-11-25 13:36:12 PST
Created attachment 43868 [details]
Add help command
Comment 2 Adam Barth 2009-11-25 13:46:12 PST
Comment on attachment 43868 [details]
Add help command

4141 class Command(object):
4242     name = None
 43     show_in_main_help = False

We should just let this inherit instead of explicitly declaring False for a bunch of concrete commands.

Otherwise looks great.
Comment 3 Eric Seidel (no email) 2009-11-25 13:49:25 PST
(In reply to comment #2)
> (From update of attachment 43868 [details])
> 4141 class Command(object):
> 4242     name = None
>  43     show_in_main_help = False
> 
> We should just let this inherit instead of explicitly declaring False for a
> bunch of concrete commands.
> 
> Otherwise looks great.

I did that at first and then I added the = False later, as it seemed to make the Commands more self-documenting.  I take it you disagree. :)  (I mentioned this in the ChangeLog.)
Comment 4 Adam Barth 2009-11-25 13:59:38 PST
The other option is to remove the default.  Having both the default and the explicit sets doesn't seem optimal.
Comment 5 Eric Seidel (no email) 2009-11-25 18:22:49 PST
Committed r51403: <http://trac.webkit.org/changeset/51403>