Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

USAGE shows SUBCOMMAND as optional despite of SubcommandRequiredElseHelp option #883

Closed
nagisa opened this issue Mar 1, 2017 · 3 comments
Labels
A-help Area: documentation, including docs.rs, readme, examples, etc... C-bug Category: Updating dependencies

Comments

@nagisa
Copy link

nagisa commented Mar 1, 2017

Rust Version

N/A

Affected Version of clap

  • 2.20.5

With

app.setting(AppSettings::SubcommandRequiredElseHelp)

the USAGE help still shows:

USAGE:
    app [dummy] [SUBCOMMAND]

It probably shouldn't show the subcommand as optional.

@kbknapp
Copy link
Member

kbknapp commented Mar 1, 2017

Agreed. Thanks!

@kbknapp kbknapp added A-help Area: documentation, including docs.rs, readme, examples, etc... C: subcommands C-bug Category: Updating dependencies labels Mar 1, 2017
@nagisa
Copy link
Author

nagisa commented Mar 1, 2017

IIRC this may also happen with SubcommandRequired option as well.

@kbknapp
Copy link
Member

kbknapp commented Mar 2, 2017

Yeah I think it's also in the same family of issues as #871 I should have some time to sit down and knock it out this family of issues tomorrow.

kbknapp added a commit that referenced this issue Mar 9, 2017
…hen AppSettings::SubcommandRequiredElseHelp is used

Close #883
kbknapp added a commit that referenced this issue Mar 9, 2017
…hen AppSettings::SubcommandRequiredElseHelp is used

Close #883
@homu homu closed this as completed in 97e8db2 Mar 11, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-help Area: documentation, including docs.rs, readme, examples, etc... C-bug Category: Updating dependencies
Projects
None yet
Development

No branches or pull requests

2 participants