mirror of
https://github.com/clap-rs/clap
synced 2024-12-14 06:42:33 +00:00
fix: Added cfg in help_template
This commit is contained in:
parent
c6058dee6e
commit
b72ad5892c
1 changed files with 7 additions and 0 deletions
|
@ -359,6 +359,13 @@ pub(crate) fn assert_app(cmd: &Command) {
|
|||
cmd.get_name(),
|
||||
"`{unified}` template variable was removed in clap3, use `{options}` instead"
|
||||
);
|
||||
#[cfg(feature = "unstable-v5")]
|
||||
assert!(
|
||||
!help_template.to_string().contains("{bin}"),
|
||||
"Command {}: {}",
|
||||
cmd.get_name(),
|
||||
"`{bin}` template variable was removed in clap5, use `{name}` instead"
|
||||
)
|
||||
}
|
||||
|
||||
cmd._panic_on_missing_help(cmd.is_help_expected_set());
|
||||
|
|
Loading…
Reference in a new issue