Open KathleenDollard opened 2 months ago
Hyphens must be supported in subcommand names (dotnet build-server
).
The root command name should allow dots too, for version numbers (myapp2.3
).
@KalleOlaviNiemitalo Thanks! I updated the description a touch.
I don't see a pressing need for --help
as a command. There is some precedent in curl --help all
but I think this can be supported by making all
an optional argument of the --help
option. IIRC, GNU getopt_long
parses an optional argument of a long option only if connected with an equals sign as in --help=all
; if System.CommandLine is made to also behave this way, i.e. parse --help all
as an option followed by an unrelated argument, then application developers should still be able to override this behavior by giving the --help
option a custom parser that consumes the all
token even if not connected.
There is the convention of a login shell getting an argv[0]
that starts with a hyphen. For example, -bash
. That should then be allowed in the root command name, too. But the .NET Runtime does not currently pass the string through to applications (https://github.com/dotnet/command-line-api/issues/2365, https://github.com/dotnet/runtime/issues/30212).
Hyphens in command names would be allowed.
Do we want to do things like allowing --help to be a command?