dotnet / dotnet/command-line-api

I expect "help" to be a subcommand

Open
#1,417 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
3.7k
Forks
428
PR merge metrics
No merged PRs in 30d

Description

When a root command has no subcommands then "help" is supported - I guess it's an implicitly-supported argument or subcommand:

foo help

When there are subcommands (e.g. `bar`) then the user requests help as an option (one of `-?` or `-h` or `--help`):

foo bar --help

But as a user I expect that "help" should be a subcommand e.g. like this:

foo help bar

Git for example supports this:

git help fetch

So I suggest you support it too, except in the case where the programmer has explicitly defined "help" as a subcommand.

Or I'd like a code snippet/sample to let me define that help subcommand myself -- i.e. to get the help text associated with other defined subcommands.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.