On Fri, 2010-10-08 at 14:23 +0200, Nikola Pajkovsky wrote:
On 10/08/2010 02:10 PM, Denys Vlasenko wrote:
> Currently, usage is an array of pointers to string.
> It is meant to support this:
>
> usage: foo --bar
> or: foo --baz
> or: foo -z
>
> The patch removes this and makes usage just a string:
>
> usage: foo --bar
>
> Why remove this?
>
> (1) We can achieve old format by using the usage string with many lines:
> usage = "foo --bar\n"
> " or: foo --baz\n"
> " or: foo -z";
>
> (2) We don't use multi-line usage anyway.
>
> Run tested.
>
> Please review.
+#define OPT__VERBOSE(v) OPT_BOOL('v', "verbose", (v), "Be
verbose")
Why upper 'B' in `Be verbose'?
First I don't see in any helps, second it looks bad and third I don't like it.
The usage text currently looks like this:
# abrtd --help
usage: abrtd [options]
-v, --verbose be verbose
-d Do not daemonize
-s Log to syslog even with -d
-t n Exit after SEC seconds of inactivity
The option descriptions should be consistent: either all start with a
capital letter, or all start with a small one. Currently, they are not
consistent.
So, should we make them all small or all capital?
I use capitalized description because sometimes there is more than one
sentence. Random example:
-C N[:MSG] Allow only up to N connections from the same IP.
New connections from this IP address are closed
immediately. MSG is written to the peer before close.
having it start with a small letter and then suddenly turn into
properly punctuated sentences would be weird.
--
vda