/third_party/rust/crates/clap/tests/builder/ |
D | derive_order.rs | 5 use clap::{Arg, ArgAction, Command}; 28 .action(ArgAction::SetTrue), in no_derive_order() 31 .action(ArgAction::Set) in no_derive_order() 36 .action(ArgAction::SetTrue), in no_derive_order() 39 .action(ArgAction::Set) in no_derive_order() 64 .action(ArgAction::SetTrue), in derive_order() 67 .action(ArgAction::Set) in derive_order() 72 .action(ArgAction::SetTrue), in derive_order() 75 .action(ArgAction::Set) in derive_order() 103 .action(ArgAction::SetTrue), in derive_order_next_order() [all …]
|
D | require.rs | 2 use clap::{arg, error::ErrorKind, Arg, ArgAction, ArgGroup, Command}; 24 .action(ArgAction::SetTrue), in flag_required_2() 26 .arg(arg!(-c --color "third flag").action(ArgAction::SetTrue)) in flag_required_2() 162 .arg(arg!(-f --flag "some flag").action(ArgAction::SetTrue)) in group_required_2() 164 .arg(arg!(--some "some arg").action(ArgAction::SetTrue)) in group_required_2() 165 .arg(arg!(--other "other arg").action(ArgAction::SetTrue)) in group_required_2() 176 .arg(arg!(-f --flag "some flag").action(ArgAction::SetTrue)) in group_required_3() 178 .arg(arg!(--some "some arg").action(ArgAction::SetTrue)) in group_required_3() 179 .arg(arg!(--other "other arg").action(ArgAction::SetTrue)) in group_required_3() 206 .action(ArgAction::SetTrue), in arg_require_group_2() [all …]
|
D | indices.rs | 1 use clap::{Arg, ArgAction, Command}; 10 .action(ArgAction::Set) in indices_mult_opts() 12 .action(ArgAction::Append), in indices_mult_opts() 17 .action(ArgAction::Set) in indices_mult_opts() 37 .action(ArgAction::Set) in index_mult_opts() 39 .action(ArgAction::Append), in index_mult_opts() 44 .action(ArgAction::Set) in index_mult_opts() 58 .arg(Arg::new("exclude").short('e').action(ArgAction::SetTrue)) in index_flag() 59 .arg(Arg::new("include").short('i').action(ArgAction::SetTrue)) in index_flag() 71 .arg(Arg::new("exclude").short('e').action(ArgAction::SetTrue)) in index_flags() [all …]
|
D | occurrences.rs | 1 use clap::{Arg, ArgAction, ArgMatches, Command}; 16 .action(ArgAction::Set) in grouped_value_works() 18 .action(ArgAction::Append), in grouped_value_works() 43 .arg(Arg::new("server").short('s').action(ArgAction::Set)) in issue_1026() 44 .arg(Arg::new("user").short('u').action(ArgAction::Set)) in issue_1026() 48 .action(ArgAction::Set) in issue_1026() 50 .action(ArgAction::Append), in issue_1026() 75 .action(ArgAction::Set) in grouped_value_long_flag_delimiter() 78 .action(ArgAction::Append), in grouped_value_long_flag_delimiter() 105 .action(ArgAction::Set) in grouped_value_short_flag_delimiter() [all …]
|
D | flags.rs | 1 use clap::{arg, Arg, ArgAction, Command}; 10 arg!(-f --flag "some flag").action(ArgAction::SetTrue), in flag_using_short() 11 arg!(-c --color "some other flag").action(ArgAction::SetTrue), in flag_using_short() 23 .arg(arg!(o: -o ... "some flag").action(ArgAction::SetTrue)) in lots_o_flags_sep() 58 .arg(arg!(o: -o ... "some flag").action(ArgAction::SetTrue)) in lots_o_flags_combined() 77 arg!(--flag "some flag").action(ArgAction::SetTrue), in flag_using_long() 78 arg!(--color "some other flag").action(ArgAction::SetTrue), in flag_using_long() 94 .action(ArgAction::SetTrue), in flag_using_long_with_literals() 105 arg!(-f --flag "some flag").action(ArgAction::SetTrue), in flag_using_mixed() 106 arg!(-c --color "some other flag").action(ArgAction::SetTrue), in flag_using_mixed() [all …]
|
D | help.rs | 3 use clap::{arg, builder::PossibleValue, error::ErrorKind, Arg, ArgAction, ArgGroup, Command}; 74 .action(ArgAction::Append), in help_multi_subcommand_error() 142 .action(ArgAction::SetTrue), in args_with_last_usage() 166 .action(ArgAction::Set) in args_with_last_usage() 330 .action(ArgAction::Append), in multi_level_sc_help() 373 .action(ArgAction::SetTrue) in wrapped_help() 379 .action(ArgAction::SetTrue) in wrapped_help() 385 .action(ArgAction::SetTrue) in wrapped_help() 391 .action(ArgAction::SetTrue) in wrapped_help() 419 .action(ArgAction::SetTrue) in unwrapped_help() [all …]
|
D | posix_compatible.rs | 1 use clap::{arg, error::ErrorKind, Arg, ArgAction, Command}; 9 .action(ArgAction::SetTrue) in flag_overrides_itself() 42 .action(ArgAction::SetTrue), in posix_compatible_flags_long() 44 .arg(arg!(--color "some other flag").action(ArgAction::SetTrue)) in posix_compatible_flags_long() 57 .action(ArgAction::SetTrue), in posix_compatible_flags_long_rev() 59 .arg(arg!(--color "some other flag").action(ArgAction::SetTrue)) in posix_compatible_flags_long_rev() 72 .action(ArgAction::SetTrue), in posix_compatible_flags_short() 74 .arg(arg!(-c --color "some other flag").action(ArgAction::SetTrue)) in posix_compatible_flags_short() 87 .action(ArgAction::SetTrue), in posix_compatible_flags_short_rev() 89 .arg(arg!(-c --color "some other flag").action(ArgAction::SetTrue)) in posix_compatible_flags_short_rev() [all …]
|
D | possible_values.rs | 1 use clap::{builder::PossibleValue, error::ErrorKind, Arg, ArgAction, Command}; 60 .action(ArgAction::Set) in possible_values_of_positional_multiple() 85 .action(ArgAction::Set) in possible_values_of_positional_multiple_fail() 102 .action(ArgAction::Set) in possible_values_of_option() 124 .action(ArgAction::Set) in possible_values_of_option_fail() 140 .action(ArgAction::Set) in possible_values_of_option_multiple() 142 .action(ArgAction::Append), in possible_values_of_option_multiple() 166 .action(ArgAction::Set) in possible_values_of_option_multiple_fail() 168 .action(ArgAction::Append), in possible_values_of_option_multiple_fail() 201 .action(ArgAction::Set) in possible_values_output() [all …]
|
D | hidden_args.rs | 3 use clap::{arg, Arg, ArgAction, Command}; 55 .action(ArgAction::SetTrue) in hide_short_args() 60 .action(ArgAction::SetTrue) in hide_short_args() 98 .action(ArgAction::SetTrue) in hide_short_args_long_help() 103 .action(ArgAction::SetTrue) in hide_short_args_long_help() 137 .action(ArgAction::SetTrue) in hide_long_args() 142 .action(ArgAction::SetTrue) in hide_long_args() 172 .action(ArgAction::SetTrue) in hide_long_args_short_help() 177 .action(ArgAction::SetTrue) in hide_long_args_short_help() 235 .arg(arg!(-h - -help).action(ArgAction::Help).hide(true)) in hide_opt_args_only() [all …]
|
D | empty_values.rs | 1 use clap::{error::ErrorKind, Arg, ArgAction, Command}; 9 .arg(Arg::new("config").long("config").action(ArgAction::Set)) in empty_values() 18 .arg(Arg::new("config").long("config").action(ArgAction::Set)) in empty_values_with_equals() 24 .arg(Arg::new("config").short('c').action(ArgAction::Set)) in empty_values_with_equals() 36 .action(ArgAction::Set) in no_empty_values() 47 .action(ArgAction::Set) in no_empty_values() 61 .action(ArgAction::Set) in no_empty_values_with_equals() 72 .action(ArgAction::Set) in no_empty_values_with_equals() 86 .action(ArgAction::Set) in no_empty_values_without_equals() 97 .action(ArgAction::Set) in no_empty_values_without_equals() [all …]
|
D | action.rs | 6 use clap::ArgAction; 11 let cmd = Command::new("test").arg(Arg::new("mammal").long("mammal").action(ArgAction::Set)); in set() 44 let cmd = Command::new("test").arg(Arg::new("mammal").long("mammal").action(ArgAction::Append)); in append() 84 Command::new("test").arg(Arg::new("mammal").long("mammal").action(ArgAction::SetTrue)); in set_true() 120 .action(ArgAction::SetTrue) in set_true_with_explicit_default_value() 144 .action(ArgAction::SetTrue) in set_true_with_default_value_if_present() 147 .arg(Arg::new("dog").long("dog").action(ArgAction::SetTrue)); in set_true_with_default_value_if_present() 171 .action(ArgAction::SetTrue) in set_true_with_default_value_if_value() 174 .arg(Arg::new("dog").long("dog").action(ArgAction::SetTrue)); in set_true_with_default_value_if_value() 198 .action(ArgAction::SetTrue) in set_true_with_required_if_eq() [all …]
|
D | env.rs | 6 use clap::{arg, builder::FalseyValueParser, Arg, ArgAction, Command}; 16 .action(ArgAction::Set), in env() 43 .action(ArgAction::SetTrue) in env_bool_literal() 50 .action(ArgAction::SetTrue) in env_bool_literal() 57 .action(ArgAction::SetTrue) in env_bool_literal() 77 .action(ArgAction::Set), in env_os() 100 .action(ArgAction::Set), in no_env() 136 .action(ArgAction::Set) in with_default() 162 .action(ArgAction::Set), in opt_user_override() 195 .action(ArgAction::Set), in positionals() [all …]
|
D | help_env.rs | 5 use clap::{Arg, ArgAction, Command}; 93 .action(ArgAction::Set), in hide_env() 110 .action(ArgAction::Set), in show_env() 128 .action(ArgAction::Set), in hide_env_vals() 145 .action(ArgAction::Set), in show_env_vals() 159 .action(ArgAction::SetTrue) in hide_env_flag() 176 .action(ArgAction::SetTrue) in show_env_flag() 192 .action(ArgAction::SetTrue) in hide_env_vals_flag() 209 .action(ArgAction::SetTrue) in show_env_vals_flag()
|
D | global_args.rs | 1 use clap::{arg, Arg, ArgAction, Command}; 11 .action(ArgAction::Set) in issue_1076() 19 .action(ArgAction::Set), in issue_1076() 35 .action(ArgAction::Set) in propagate_global_arg_in_subcommand_to_subsubcommand_1385() 93 .action(ArgAction::SetTrue), in global_arg_available_in_subcommand() 97 .action(ArgAction::SetTrue), in global_arg_available_in_subcommand() 114 .arg(arg!(--"long-a").global(true).action(ArgAction::SetTrue)) in deeply_nested_discovery() 117 .arg(arg!(--"long-b").global(true).action(ArgAction::SetTrue)) in deeply_nested_discovery() 120 .arg(arg!(--"long-c").global(true).action(ArgAction::SetTrue)) in deeply_nested_discovery() 142 .action(ArgAction::Set) in global_overrides_default() [all …]
|
D | flag_subcommands.rs | 3 use clap::{arg, error::ErrorKind, Arg, ArgAction, Command}; 14 .action(ArgAction::SetTrue), in flag_subcommand_normal() 38 .action(ArgAction::SetTrue), in flag_subcommand_normal_with_alias() 60 .action(ArgAction::SetTrue), in flag_subcommand_short() 81 .action(ArgAction::SetTrue), in flag_subcommand_short_with_args() 104 .action(ArgAction::SetTrue), in flag_subcommand_short_with_alias() 178 .action(ArgAction::SetTrue), in flag_subcommand_short_with_aliases() 235 .arg(Arg::new("clean").short('c').action(ArgAction::SetTrue)), in flag_subcommand_short_after_long_arg() 237 .arg(Arg::new("arg").long("arg").action(ArgAction::Set)) in flag_subcommand_short_after_long_arg() 255 .action(ArgAction::SetTrue), in flag_subcommand_long() [all …]
|
D | multiple_values.rs | 1 use clap::{error::ErrorKind, Arg, ArgAction, Command}; 10 .action(ArgAction::Set) in option_long() 12 .action(ArgAction::Append), in option_long() 38 .action(ArgAction::Set) in option_short() 40 .action(ArgAction::Append), in option_short() 65 .action(ArgAction::Set) in option_mixed() 67 .action(ArgAction::Append), in option_mixed() 94 .action(ArgAction::Append), in option_exact_exact() 145 .action(ArgAction::Append), in option_exact_exact_mult() 172 .action(ArgAction::Append), in option_exact_less() [all …]
|
/third_party/rust/crates/clap/clap_mangen/tests/ |
D | common.rs | 9 .action(clap::ArgAction::SetTrue), in basic_command() 15 .action(clap::ArgAction::SetTrue), in basic_command() 21 .action(clap::ArgAction::Count), in basic_command() 38 .action(clap::ArgAction::Count) in feature_sample_command() 50 .action(clap::ArgAction::Set) in feature_sample_command() 64 .action(clap::ArgAction::Set) in special_commands_command() 77 .action(clap::ArgAction::SetTrue) in quoting_command() 83 .action(clap::ArgAction::SetTrue) in quoting_command() 89 .action(clap::ArgAction::SetTrue) in quoting_command() 95 .action(clap::ArgAction::SetTrue) in quoting_command() [all …]
|
/third_party/rust/crates/clap/clap_bench/benches/ |
D | 06_rustup.rs | 5 use clap::{Arg, ArgAction, ArgGroup, Command}; 34 .action(ArgAction::SetTrue), in build_cli() 57 .action(ArgAction::SetTrue) in build_cli() 113 .action(ArgAction::Set), in build_cli() 123 .action(ArgAction::Set), in build_cli() 133 .action(ArgAction::Set), in build_cli() 143 .action(ArgAction::Set), in build_cli() 153 .action(ArgAction::Set), in build_cli() 166 .action(ArgAction::Set), in build_cli() 176 .action(ArgAction::Set), in build_cli() [all …]
|
D | 05_ripgrep.rs | 6 use clap::{value_parser, Arg, ArgAction, Command}; 299 let flag = |name| arg(name).long(name).action(ArgAction::SetTrue); in cmd() 330 .action(ArgAction::Append) in cmd() 346 .action(ArgAction::Set) in cmd() 350 .arg(flag("colors").value_name("SPEC").action(ArgAction::Append)) in cmd() 355 .action(ArgAction::Append) in cmd() 365 .action(ArgAction::Append) in cmd() 371 .action(ArgAction::Append) in cmd() 374 .arg(flag("unrestricted").short('u').action(ArgAction::Append)) in cmd() 381 .action(ArgAction::Set) in cmd() [all …]
|
D | 03_complex.rs | 1 use clap::{arg, Arg, ArgAction, Command}; 59 .action(ArgAction::Append), in build_from_builder() 68 .action(ArgAction::Count), in build_from_builder() 74 .action(ArgAction::SetTrue) in build_from_builder() 83 .action(ArgAction::Set) in build_from_builder() 95 .action(ArgAction::Set) in build_from_builder() 115 .action(ArgAction::Append) in build_from_builder() 122 .action(ArgAction::Append) in build_from_builder() 129 .action(ArgAction::Append) in build_from_builder() 143 .action(ArgAction::Append) in build_from_builder()
|
/third_party/rust/crates/clap/src/ |
D | macros.rs | 208 …debug_assert!(!matches!($arg.get_action(), $crate::ArgAction::Append), "Flags should precede `...`… 215 let action = $crate::ArgAction::SetTrue; 231 …debug_assert!(!matches!($arg.get_action(), $crate::ArgAction::Append), "Flags should precede `...`… 238 let action = $crate::ArgAction::SetTrue; 255 …debug_assert!(!matches!($arg.get_action(), $crate::ArgAction::Append), "Flags should precede `...`… 257 let action = $crate::ArgAction::SetTrue; 274 …debug_assert!(!matches!($arg.get_action(), $crate::ArgAction::Append), "Flags should precede `...`… 276 let action = $crate::ArgAction::SetTrue; 291 …debug_assert!(!matches!($arg.get_action(), $crate::ArgAction::Append), "Flags should precede `...`… 306 .action($crate::ArgAction::Set); [all …]
|
/third_party/rust/crates/clap/clap_complete/tests/ |
D | common.rs | 9 .action(clap::ArgAction::SetTrue), in basic_command() 15 .action(clap::ArgAction::SetTrue), in basic_command() 21 .action(clap::ArgAction::Count), in basic_command() 38 .action(clap::ArgAction::Count) in feature_sample_command() 50 .action(clap::ArgAction::Set) in feature_sample_command() 65 .action(clap::ArgAction::Set) in special_commands_command() 81 .action(clap::ArgAction::SetTrue) in quoting_command() 87 .action(clap::ArgAction::SetTrue) in quoting_command() 93 .action(clap::ArgAction::SetTrue) in quoting_command() 99 .action(clap::ArgAction::SetTrue) in quoting_command() [all …]
|
/third_party/rust/crates/clap/clap_complete_fig/tests/ |
D | common.rs | 7 .action(clap::ArgAction::SetTrue), in basic_command() 13 .action(clap::ArgAction::SetTrue), in basic_command() 19 .action(clap::ArgAction::Count), in basic_command() 36 .action(clap::ArgAction::Count) in feature_sample_command() 48 .action(clap::ArgAction::Set) in feature_sample_command() 63 .action(clap::ArgAction::Set) in special_commands_command() 79 .action(clap::ArgAction::SetTrue) in quoting_command() 85 .action(clap::ArgAction::SetTrue) in quoting_command() 91 .action(clap::ArgAction::SetTrue) in quoting_command() 97 .action(clap::ArgAction::SetTrue) in quoting_command() [all …]
|
/third_party/rust/crates/clap/tests/ |
D | macros.rs | 46 assert!(matches!(arg.get_action(), clap::ArgAction::SetTrue)); in short() 54 assert!(matches!(arg.get_action(), clap::ArgAction::SetTrue)); in short() 62 assert!(matches!(arg.get_action(), clap::ArgAction::Count)); in short() 70 assert!(matches!(arg.get_action(), clap::ArgAction::SetTrue)); in short() 85 assert!(matches!(arg.get_action(), clap::ArgAction::SetTrue)); in short_and_long() 94 assert!(matches!(arg.get_action(), clap::ArgAction::SetTrue)); in short_and_long() 103 assert!(matches!(arg.get_action(), clap::ArgAction::Count)); in short_and_long() 112 assert!(matches!(arg.get_action(), clap::ArgAction::SetTrue)); in short_and_long() 124 assert!(matches!(arg.get_action(), clap::ArgAction::SetTrue)); in short_help() 128 .arg(clap::arg!(help: -b).action(clap::ArgAction::Help)); in short_help() [all …]
|
/third_party/rust/crates/clap/examples/derive_ref/ |
D | flatten_hand_args.rs | 2 use clap::{Arg, ArgAction, ArgMatches, Args, Command, FromArgMatches, Parser}; 43 .action(ArgAction::SetTrue), in augment_args() 49 .action(ArgAction::SetTrue), in augment_args() 55 .action(ArgAction::Set), in augment_args() 63 .action(ArgAction::SetTrue), in augment_args_for_update() 69 .action(ArgAction::SetTrue), in augment_args_for_update() 75 .action(ArgAction::Set), in augment_args_for_update()
|