diff --git a/Cargo.toml b/Cargo.toml index e2cdb52d618..65d2abcf4a0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -138,7 +138,7 @@ libp2p-gossipsub = { version = "0.42.1", path = "protocols/gossipsub", optional async-std = { version = "1.6.2", features = ["attributes"] } async-trait = "0.1" env_logger = "0.9.0" -clap = { version = "3.1.6", features = ["derive"] } +clap = { version = "4.0.13", features = ["derive"] } tokio = { version = "1.15", features = ["io-util", "io-std", "macros", "rt", "rt-multi-thread"] } [workspace] diff --git a/misc/keygen/Cargo.toml b/misc/keygen/Cargo.toml index 6aaf01fbc4e..a5007fcb499 100644 --- a/misc/keygen/Cargo.toml +++ b/misc/keygen/Cargo.toml @@ -10,7 +10,7 @@ categories = ["network-programming", "asynchronous"] publish = false [dependencies] -clap = {version = "3.1.6", features = ["derive"]} +clap = { version = "4.0.13", features = ["derive"] } zeroize = "1" serde = { version = "1.0.136", features = ["derive"] } serde_json = "1.0.79" diff --git a/misc/keygen/src/main.rs b/misc/keygen/src/main.rs index 7c2de2a181c..4d298477513 100644 --- a/misc/keygen/src/main.rs +++ b/misc/keygen/src/main.rs @@ -27,7 +27,7 @@ enum Command { /// Read from config file From { /// Provide a IPFS config file - #[clap(parse(from_os_str))] + #[clap(value_parser)] config: PathBuf, }, /// Generate random diff --git a/protocols/autonat/Cargo.toml b/protocols/autonat/Cargo.toml index ed117c9edf4..c3b88583839 100644 --- a/protocols/autonat/Cargo.toml +++ b/protocols/autonat/Cargo.toml @@ -28,5 +28,5 @@ prost = "0.11" [dev-dependencies] async-std = { version = "1.10", features = ["attributes"] } env_logger = "0.9" -clap = {version = "3.1.6", features = ["derive"]} +clap = { version = "4.0.13", features = ["derive"] } libp2p = { path = "../..", features = ["full"] } diff --git a/protocols/dcutr/Cargo.toml b/protocols/dcutr/Cargo.toml index dbdf9494d9b..d9cc5861bc5 100644 --- a/protocols/dcutr/Cargo.toml +++ b/protocols/dcutr/Cargo.toml @@ -32,4 +32,4 @@ prost-build = "0.11" env_logger = "0.9.0" libp2p = { path = "../..", features = ["full"] } rand = "0.8" -clap = {version = "3.1.6", features = ["derive"]} +clap = { version = "4.0.13", features = ["derive"] } diff --git a/protocols/dcutr/examples/dcutr.rs b/protocols/dcutr/examples/dcutr.rs index 925e03593b5..9e17539d269 100644 --- a/protocols/dcutr/examples/dcutr.rs +++ b/protocols/dcutr/examples/dcutr.rs @@ -60,7 +60,7 @@ struct Opts { remote_peer_id: Option, } -#[derive(Debug, Parser, PartialEq)] +#[derive(Clone, Debug, PartialEq, Parser)] enum Mode { Dial, Listen, diff --git a/protocols/relay/Cargo.toml b/protocols/relay/Cargo.toml index 052eb1127a8..19837380355 100644 --- a/protocols/relay/Cargo.toml +++ b/protocols/relay/Cargo.toml @@ -36,4 +36,4 @@ prost-build = "0.11" env_logger = "0.9.0" libp2p = { path = "../..", features = ["full"] } quickcheck = { package = "quickcheck-ext", path = "../../misc/quickcheck-ext" } -clap = {version = "3.1.6", features = ["derive"]} +clap = { version = "4.0.13", features = ["derive"] }