(Sorry for not quoting names. It’s cumbersome to do with more than one
person in Gmail.)

> With the above rules this should be: flo [-cfrtw arg] [what[,from][-to]]

I think that’s too little information.

> It also just makes the usage easier to read, in my opinion. Dropping a
> few characters just isn't worth any loss in clarity.

Valid point. Make things as simple as possible, but not simpler. :)

>From the information that I have now, then I would think that this
should be fine:

usage: program [-a] [-b] [-c] [-f file] [-n number] blah
usage: flo [-a] [-c id] [-f from] [-r id] [-t to] [-w what] [what[,from][-to]]

I’d like to write a KISS option parser that accepts “program -c -a -f
some_file”, but not “program -ca -fsome_file”. I prefer to keep the
rules simple.

Is it okay to use three dots in the usage text? (See echo’s man page.)
I think it means that you can repeat what’s before the three dots.

How do you feel about sorting the options? Should it always be done?

Reply via email to