[Freeipa-devel] [PATCH] Add more sophisticated help interface. Split commands into 'topics'.

Rob Crittenden rcritten at redhat.com
Wed Apr 15 17:00:08 UTC 2009


Pavel Zuna wrote:
> This is more of a suggestion than a real patch. I thought it might be 
> easier to actually show what I had in mind than explaining it. Sometimes 
> code is more than words. :)
> 
> Pavel

I think this is a good start. The output looks like:

$ ipa
Usage: ipa [global-options] COMMAND ...

Use `ipa help TOPIC` for command listings.

Topics:
   general      General IPA management.
   aci          ACI object.
   application  Application object
   automount    Automount object.
   delegation   Delegation object.
   group        group object.
   host         Host object.
   hostgroup    hostgroup object.
   netgroup     netgroup object.
   rolegroup    rolegroup object.
   service      Service object.
   taskgroup    taskgroup object.
   user         User object.

Try `ipa --help` for a list of global options.

It looks like you dumped things that aren't related to a top-level class 
into general (things like passwd, the cert commands, and a few others). 
I guess they have to go somewhere, just not sure I'd know to look in 
general if I was a new user.

Should we mandate an Object for every plugin? Or include the list of 
these general commands in the main topics list? That might be confusing 
too because that would mean that 'env' is on the same level as 'user'.

Any suggestions?

The patch is good and we could easily just apply this but I don't want 
to forget about these issues. In any case we'll want to go into each 
plugin and set the Object documentation to be more descriptive.

rob




More information about the Freeipa-devel mailing list