commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Emmanuel Bourg <ebo...@apache.org>
Subject Re: [cli] Avalon CLI vs Commons CLI 1.x
Date Thu, 24 Jul 2008 23:57:49 GMT
Jörg Schaible a écrit :

> Hmmm. I always thought that using the long option the '=' is mandatory while
> for a short option space is optional. 

I checked the documentation for getopt [1], the '=' sign after a long 
option is required only if the argument is optional. Same thing for the 
short options, if the argument is optional it must be grouped with the 
option (-O1 and not -O 1).

So Avalon CLI is right. The catch now if we implement this is to decide 
how multiple optional arguments are handled. I guess this would make the 
value separator mandatory:

--foo=a,b,c

or

-fa,b,c

Emmanuel Bourg


[1] http://www.urbanophile.com/arenn/hacking/getopt/gnu.getopt.Getopt.html

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Mime
View raw message