[Mono-list] Command line processing tool in C#
A Rafael D Teixeira
rafael.teixeirabr@terra.com.br
Tue, 04 May 2004 10:23:16 -0300
Inline,
Context of this thread: Now talking about Mono.GetOptions
On Sun, 2004-05-02 at 14:27, Thomas R. Corbin wrote:
> On Thursday April 08, 2004 11:33 am, A Rafael D Teixeira wrote:
> > Inline...
>
> This stuff is really excellent, and I am really enjoying using it.
>
> I'm wondering, however, if there's a way to specify a default value for an
> option, for display in the --help output?
Currently you set the value with an initializer and write about it on
the description.
<snip>
...
[Option("The maximum {number} of times to retry the connection [default = 4]", 'r', "retries")]
public int retries = 4;
...
</snip>
But if you want it open a wishlist-type case in bugzilla for it, please.
After Mono 1.0, probably I'll find some time to work on it. Something
like
<snip>
...
[Option("The maximum {number} of times to retry the connection [default = @default]", 'r', "retries")]
public int retries = 5;
...
</snip>
The expected result would be a line in help like
-r --retries:number The maximum number of times to retry the connection [default = 5]
Suggestions welcome!!!
Best regards,
--
Rafael "Monoman" Teixeira
Mono Hacker since 16 Jul 2001 - http://www.go-mono.org/
Mono Brasil Founding Member - http://monobrasil.redesolbrasil.org/
English Blog: http://monoblog.blogspot.com/
Brazilian Portuguese Blog: http://monoblog.weblogger.terra.com.br/