diff --git a/cli/Cargo.toml b/cli/Cargo.toml index 3b14972..d0b0a2c 100644 --- a/cli/Cargo.toml +++ b/cli/Cargo.toml @@ -9,10 +9,10 @@ license = "GPL-3.0-or-later" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -omegaupload-common = "0.2" +omegaupload-common = "0.2.0" -anyhow = "1" -atty = "0.2" -clap = { version = "3", features = ["derive"] } -reqwest = { version = "0.11", default-features = false, features = ["rustls-tls", "blocking"] } -rpassword = "5" +anyhow = "1.0.58" +atty = "0.2.14" +clap = { version = "3.2.8", features = ["derive"] } +reqwest = { version = "0.11.11", default-features = false, features = ["rustls-tls", "blocking"] } +rpassword = "6.0.1" diff --git a/cli/src/main.rs b/cli/src/main.rs index b80bcca..1ac3907 100644 --- a/cli/src/main.rs +++ b/cli/src/main.rs @@ -31,7 +31,7 @@ use omegaupload_common::{ use reqwest::blocking::Client; use reqwest::header::EXPIRES; use reqwest::StatusCode; -use rpassword::prompt_password_stderr; +use rpassword::prompt_password; use crate::fragment::Builder; @@ -120,8 +120,7 @@ fn handle_upload( } let password = if password { - let maybe_password = - prompt_password_stderr("Please set the password for this paste: ")?; + let maybe_password = prompt_password("Please set the password for this paste: ")?; Some(SecretVec::new(maybe_password.into_bytes())) } else { None @@ -200,8 +199,7 @@ fn handle_download(mut url: ParsedUrl) -> Result<()> { let password = if url.needs_password { // Only print prompt on interactive, else it messes with output - let maybe_password = - prompt_password_stderr("Please enter the password to access this paste: ")?; + let maybe_password = prompt_password("Please enter the password to access this paste: ")?; Some(SecretVec::new(maybe_password.into_bytes())) } else { None