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

Add AppSettings::DisableHyphenSubcommand to allow removing hyphen in help messages #2738

Closed
wants to merge 1 commit into from

Conversation

fanzeyi
Copy link

@fanzeyi fanzeyi commented Aug 25, 2021

Related to #1431 but this does not completely close the issue as this only implemented the setting for v2.

$ cargo test --test app_settings
...
test result: ok. 63 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.02s

Example:

let res = App::new("myprog")
    .subcommand(SubCommand::with_name("test").setting(AppSettings::DisableHyphenSubcommand))
    .get_matches_from_safe(vec![
        "myprog", "test", "--help"
    ]);
assert!(res.is_err());
assert!(res.unwrap_err().message.starts_with("myprog test"));

@epage
Copy link
Member

epage commented Aug 25, 2021

@pksunkara Whats the bar for features going into v2?

@pksunkara
Copy link
Member

We don't allow it. Only security fixes. Please redo the pr for master branch

@pksunkara pksunkara closed this Aug 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants