[Gambas-user] Args help , most other places is -?
benoit.minisini at gambas-basic.org
Thu Jun 30 00:11:01 CEST 2022
Le 29/06/2022 à 13:51, Bruce Steers a écrit :
> I just noticed something in the Args.class
> Help is checked like this..
> If Has("h", "help", ("Display this help")) Then
> I have noticed most other software uses -? not -h as the short name.
> I've edited gb.args Args.Has to be able to use more than one char for
> Args.Has("?h", "help", "Show this help")
> will work with either -? or -h
> What do you think Ben?
> I've submitted a merge request..
I don't see the need for that: '-?' and '-h' being synonymous is the
only sane case I can imagine (because you want help, and so you don't
know the options).
Another point: I didn't notice that you added a 'Args.HelpText()' method
with an optional argument. It's quite an ugly interface! Why whould you
need the automatically generated text as a string instead of printing it?
More information about the User