Update clap

This commit is contained in:
Benjamin Saunders
2022-10-22 20:04:52 -07:00
committed by Dirkjan Ochtman
parent a66ee19797
commit 044eab53ff
7 changed files with 12 additions and 13 deletions
+1 -1
View File
@@ -13,7 +13,7 @@ hdrhistogram = { version = "7.2", default-features = false }
quinn = { path = "../quinn" }
rcgen = "0.10.0"
rustls = { version = "0.21.0", default-features = false, features = ["quic"] }
clap = { version = "3.2", features = ["derive"] }
clap = { version = "4", features = ["derive"] }
tokio = { version = "1.0.1", features = ["rt", "sync"] }
tracing = "0.1.10"
tracing-subscriber = { version = "0.3.0", default-features = false, features = ["env-filter", "fmt", "ansi", "time", "local-time"] }
+4 -4
View File
@@ -161,15 +161,15 @@ pub struct Opt {
pub max_streams: usize,
/// Number of bytes to transmit from server to client
///
/// This can use SI prefixes for sizes. E.g. 1M will transfer 1MiB, 10GiB
/// This can use SI prefixes for sizes. E.g. 1M will transfer 1MiB, 10G
/// will transfer 10GiB.
#[clap(long, default_value = "1G", parse(try_from_str = parse_byte_size))]
#[clap(long, default_value = "1G", value_parser = parse_byte_size)]
pub download_size: u64,
/// Number of bytes to transmit from client to server
///
/// This can use SI prefixes for sizes. E.g. 1M will transfer 1MiB, 10GiB
/// This can use SI prefixes for sizes. E.g. 1M will transfer 1MiB, 10G
/// will transfer 10GiB.
#[clap(long, default_value = "0", parse(try_from_str = parse_byte_size))]
#[clap(long, default_value = "0", value_parser = parse_byte_size)]
pub upload_size: u64,
/// Show connection stats the at the end of the benchmark
#[clap(long = "stats")]
+1 -1
View File
@@ -23,7 +23,7 @@ serde = { version = "1.0", features = ["derive"], optional = true }
serde_json = { version = "1.0", optional = true }
socket2 = "0.5"
webpki = "0.22"
clap = { version = "3.2", features = ["derive"] }
clap = { version = "4", features = ["derive"] }
tokio = { version = "1.0.1", features = ["rt", "macros", "signal", "net", "sync"] }
tracing = "0.1.10"
tracing-subscriber = { version = "0.3.0", default-features = false, features = ["env-filter", "fmt", "ansi", "time", "local-time"] }
+2 -2
View File
@@ -15,10 +15,10 @@ struct Opt {
#[clap(long = "listen", default_value = "[::]:4433")]
listen: SocketAddr,
/// TLS private key in DER format
#[clap(parse(from_os_str), short = 'k', long = "key", requires = "cert")]
#[clap(short = 'k', long = "key", requires = "cert")]
key: Option<PathBuf>,
/// TLS certificate in PEM format
#[clap(parse(from_os_str), short = 'c', long = "cert", requires = "key")]
#[clap(short = 'c', long = "cert", requires = "key")]
cert: Option<PathBuf>,
/// Send buffer size in bytes
#[clap(long, default_value = "2097152")]
+1 -1
View File
@@ -56,7 +56,7 @@ directories-next = "2"
rand = "0.8"
rcgen = "0.10.0"
rustls-pemfile = "1.0.0"
clap = { version = "3.2", features = ["derive"] }
clap = { version = "4", features = ["derive"] }
tokio = { version = "1.28.1", features = ["rt", "rt-multi-thread", "time", "macros", "sync"] }
tracing-subscriber = { version = "0.3.0", default-features = false, features = ["env-filter", "fmt", "ansi", "time", "local-time"] }
tracing-futures = { version = "0.2.0", default-features = false, features = ["std-future"] }
+1 -1
View File
@@ -33,7 +33,7 @@ struct Opt {
host: Option<String>,
/// Custom certificate authority to trust, in DER format
#[clap(parse(from_os_str), long = "ca")]
#[clap(long = "ca")]
ca: Option<PathBuf>,
/// Simulate NAT rebinding after connecting
+2 -3
View File
@@ -24,13 +24,12 @@ struct Opt {
#[clap(long = "keylog")]
keylog: bool,
/// directory to serve files from
#[clap(parse(from_os_str))]
root: PathBuf,
/// TLS private key in PEM format
#[clap(parse(from_os_str), short = 'k', long = "key", requires = "cert")]
#[clap(short = 'k', long = "key", requires = "cert")]
key: Option<PathBuf>,
/// TLS certificate in PEM format
#[clap(parse(from_os_str), short = 'c', long = "cert", requires = "key")]
#[clap(short = 'c', long = "cert", requires = "key")]
cert: Option<PathBuf>,
/// Enable stateless retries
#[clap(long = "stateless-retry")]