Conversation
Bibiko
commented
Sep 28, 2012
- restructured general help output plus some changes in command descriptions
- fixed bug of returning the underlying object for command "menu"
- added the chance to add submenus (via key menu = {...}) for command "menu"
- added the chance to return only value(s) for commands returning a plist by specifying the option "--output " or "--output '(array,of,keys)'" (esp. meant for BASH scripting or piping result)
• `$DIALOG help` now outputs a sorted and more structured list of registered commands
…f separators or headers by setting and passing [NSMenuItem representedObject] • add the chance to add submenus by the dictionary key "menu" and the same top level structure (see $DIALOG help menu)
…g a property list by adding the option '--output <key(s)>' - changed [TMDCommand writePropertyList:toFileHandle: withProxy:] - added "Options" to general help output
|
Why did you move to a multi-line summary? Normally summary should be short and the user can then do As for I’m a little unclear on the “arrays of keys” — what is the format of this? Is that ASCII plist array syntax? Do we really want to support that? |
|
• Re: multi-line summary • I'll also rename --output to --filter. • Re: arrays of keys --filter '(foo,bar)' will return a plain text string where the values of the keys foo and bar are delimited by a new line \n . This format can be read quite easily with any language. To read a plist with Perl e.g., well one has to install such a package in beforehand. Regards, |
|
OK, btw: when you write commit messages please first write a summary of the commit’s changes (one short line) and then a blank line followed by detailed description / analysis. Your current style (without the blank line and with the bullet) has git confused, try e.g.: (note I also broke up one of your commits into two, since it was both fixing a bug and introducing a feature, we generally want each fix/change isolated in its own commit) |
- only one line for description - made usage output more consistent - added missing options to usage
- --icon argument can be a valid image file path or a known image name - --suppression 'title' shows a check box with 'title' as label; the state of this check box will returned as 'suppressionButtonState' in the plist
|
Allan, is it now Ok? I also added to command 'alert' the options --icon and --suppression for more flexibility Cheers, |
|
You added 3 new commits rather than cleanup the existing 3 commits. As for array of keys, I think we should drop this option as it seems very ad hoc and not self-explanatory from the help alone. It also seems the same can be achieved by setting a custom key in the plist with multiple newline delimited values, and ask to get that key back (untested); though I’d say if doing “complex” stuff with |
|
P.S. Sorry it took so long to reply. |