argparse icon indicating copy to clipboard operation
argparse copied to clipboard

Parser for command-line arguments

Results 14 argparse issues
Sort by recently updated
recently updated
newest added

``` import std; import argparse; @Command("c1") struct command1 { bool c1data; } @Command("c2") struct command2 { @NamedArgument bool c2data; } struct Program { @NamedArgument("numbers") bool numbers; SumType!(command1, command2) cmd; }...

e.g. for me --help does not print the subcommands if I do not Annotate their SumType with @SubCommands. Also the first subsection reads `Subcommands without UDA` which indices for me,...

I have no idea why, but I don't see any colors in the help text in the bash terminal of Visual Studio Code. I see colors in a separate terminal....

```d auto myBold = bold; assert(is(typeof(myBold("text")) == string)); assert(!is(typeof(bold("text")): string)); // Not even convertible. ``` (That’s because `bold()("text")` returns `string` while `bold("text")` returns `StyledText`.) IMHO, it shouldn’t work like this....

I was playing with rust/clap and one feature I really liked there was, that you can use doc-comments as an alternative to annotations to document flags/commands... Not sure that its...

enhancement

Discovered this when I was trying to deduplicate `Complete.InitCmd`. A reduced example that should be easier to follow: ```d struct Description { string delegate() dg; } auto createCompleter(string desc) {...

bug

Fix: `dub test --build=unittest-cov-ctfe --verbose`. https://dub.pm/package-format-sdl.html#build-types

wontfix

I think, apart from being case-sensitive or case-insensitive, there is a third practically useful approach: ignore case in long options but be case-sensitive in short ones. The reason is that...

enhancement

An example from the Readme, reduced: ```d import argparse; struct T { @(PositionalArgument(0).Description(() => "Argument description")) string param0; } void main() { CLI!T.parseArgs!((T t) { })(["-h"]); // SIGILL } ```...