mirror of
https://github.com/clap-rs/clap
synced 2024-12-13 06:12:40 +00:00
docs(clap_app!): documents the --("some-arg")
method for using args with hyphens inside them
Closes #919
This commit is contained in:
parent
59272b06cc
commit
bc08ef3e18
1 changed files with 2 additions and 0 deletions
|
@ -562,6 +562,8 @@ macro_rules! app_from_crate {
|
|||
///
|
||||
/// * A single hyphen followed by a character (such as `-c`) sets the [`Arg::short`]
|
||||
/// * A double hyphen followed by a character or word (such as `--config`) sets [`Arg::long`]
|
||||
/// * If one wishes to use a [`Arg::long`] with a hyphen inside (i.e. `--config-file`), you
|
||||
/// must use `--("config-file")` due to limitations of the Rust macro system.
|
||||
/// * Three dots (`...`) sets [`Arg::multiple(true)`]
|
||||
/// * Angled brackets after either a short or long will set [`Arg::value_name`] and
|
||||
/// `Arg::required(true)` such as `--config <FILE>` = `Arg::value_name("FILE")` and
|
||||
|
|
Loading…
Reference in a new issue