Skip to content

Commit ebbb375

Browse files
committed
Use std::env::home_dir() instead of the home crate
1 parent fd19814 commit ebbb375

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ async-trait = "0.1"
2020
base64 = "0.22"
2121
bytes = "1"
2222
chrono = { version = "0.4.31", features = ["serde"] }
23-
home = "0.5.5"
2423
http = "1"
2524
http-body-util = "0.1"
2625
hyper = { version = "1", default-features = false, features = ["client", "http1", "http2"] }

src/config_default_credentials.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
#[cfg(target_family = "unix")]
2+
use std::env;
13
use std::path::PathBuf;
24
use std::sync::Arc;
35

@@ -110,7 +112,7 @@ struct RefreshRequest<'a> {
110112

111113
#[cfg(target_family = "unix")]
112114
fn config_dir() -> Result<PathBuf, Error> {
113-
let mut home = home::home_dir().ok_or(Error::Str("home directory not found"))?;
115+
let mut home = env::home_dir().ok_or(Error::Str("home directory not found"))?;
114116
home.push(CONFIG_DIR);
115117
Ok(home)
116118
}

0 commit comments

Comments
 (0)