mirror of
https://github.com/clap-rs/clap
synced 2024-11-10 06:44:16 +00:00
chore(README.md): remove deprecated Arg::new() for Arg::with_name()
This commit is contained in:
parent
3c217b22b9
commit
2b3d3fd901
1 changed files with 4 additions and 4 deletions
|
@ -121,16 +121,16 @@ fn main() {
|
|||
.version("1.0")
|
||||
.author("Kevin K. <kbknapp@gmail.com>")
|
||||
.about("Does awesome things")
|
||||
.arg(Arg::new("CONFIG")
|
||||
.arg(Arg::with_name("CONFIG")
|
||||
.short("c")
|
||||
.long("config")
|
||||
.help("Sets a custom config file")
|
||||
.takes_value(true))
|
||||
.arg(Arg::new("INPUT")
|
||||
.arg(Arg::with_name("INPUT")
|
||||
.help("Sets the input file to use")
|
||||
.required(true)
|
||||
.index(1))
|
||||
.arg(Arg::new("debug")
|
||||
.arg(Arg::with_name("debug")
|
||||
.short("d")
|
||||
.multiple(true)
|
||||
.help("Sets the level of debugging information"))
|
||||
|
@ -138,7 +138,7 @@ fn main() {
|
|||
.about("controls testing features")
|
||||
.version("1.3")
|
||||
.author("Someone E. <someone_else@other.com>")
|
||||
.arg(Arg::new("verbose")
|
||||
.arg(Arg::with_name("verbose")
|
||||
.short("v")
|
||||
.help("print test information verbosely")))
|
||||
.get_matches();
|
||||
|
|
Loading…
Reference in a new issue