mirror of
https://github.com/koverstreet/bcachefs-tools.git
synced 2025-03-28 00:00:03 +03:00
rust: bump rpassword to v7.x
Including a tiny API change. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
f5baaf48e3
commit
06ff8b55b7
17
Cargo.lock
generated
17
Cargo.lock
generated
@ -536,12 +536,23 @@ checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f"
|
||||
|
||||
[[package]]
|
||||
name = "rpassword"
|
||||
version = "4.0.5"
|
||||
version = "7.3.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "99371657d3c8e4d816fb6221db98fa408242b0b53bac08f8676a41f8554fe99f"
|
||||
checksum = "80472be3c897911d0137b2d2b9055faf6eeac5b14e324073d83bc17b191d7e3f"
|
||||
dependencies = [
|
||||
"libc",
|
||||
"winapi",
|
||||
"rtoolbox",
|
||||
"windows-sys 0.48.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "rtoolbox"
|
||||
version = "0.0.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c247d24e63230cdb56463ae328478bd5eac8b8faa8c69461a77e8e323afac90e"
|
||||
dependencies = [
|
||||
"libc",
|
||||
"windows-sys 0.48.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
@ -22,6 +22,6 @@ uuid = "1.2.2"
|
||||
gag = "1.0.0"
|
||||
errno = "0.2"
|
||||
either = "1.5"
|
||||
rpassword = "4"
|
||||
rpassword = "7"
|
||||
bch_bindgen = { path = "bch_bindgen" }
|
||||
byteorder = "1.3"
|
||||
|
@ -87,7 +87,7 @@ fn ask_for_key(sb: &bch_sb_handle) -> anyhow::Result<()> {
|
||||
let bch_key_magic = BCH_KEY_MAGIC.as_bytes().read_u64::<LittleEndian>().unwrap();
|
||||
let crypt = sb.sb().crypt().unwrap();
|
||||
let pass = if atty::is(atty::Stream::Stdin) {
|
||||
rpassword::read_password_from_tty(Some("Enter passphrase: "))?
|
||||
rpassword::prompt_password("Enter passphrase: ")?
|
||||
} else {
|
||||
let mut line = String::new();
|
||||
std::io::stdin().read_line(&mut line)?;
|
||||
|
Loading…
Reference in New Issue
Block a user