Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Swap dirs-next dependency to cargo-team maintained home crate #1207

Merged
merged 2 commits into from
Jul 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions kube-client/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ gzip = ["client", "tower-http/decompression-gzip"]
client = ["config", "__non_core", "hyper", "http-body", "tower", "tower-http", "hyper-timeout", "pin-project", "chrono", "jsonpath_lib", "bytes", "futures", "tokio", "tokio-util", "either"]
jsonpatch = ["kube-core/jsonpatch"]
admission = ["kube-core/admission"]
config = ["__non_core", "pem", "dirs"]
config = ["__non_core", "pem", "home"]

# private feature sets; do not use
__non_core = ["tracing", "serde_yaml", "base64"]
Expand All @@ -39,7 +39,7 @@ rustdoc-args = ["--cfg", "docsrs"]
[dependencies]
base64 = { version = "0.20.0", optional = true }
chrono = { version = "0.4.23", optional = true, default-features = false }
dirs = { package = "dirs-next", optional = true, version = "2.0.0" }
home = { version = "0.5.4", optional = true }
serde = { version = "1.0.130", features = ["derive"] }
serde_json = "1.0.68"
serde_yaml = { version = "0.9.19", optional = true }
Expand Down
3 changes: 1 addition & 2 deletions kube-client/src/config/file_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -555,8 +555,7 @@ fn ensure_trailing_newline(mut data: Vec<u8>) -> Vec<u8> {

/// Returns kubeconfig path from `$HOME/.kube/config`.
fn default_kube_path() -> Option<PathBuf> {
use dirs::home_dir;
home_dir().map(|h| h.join(".kube").join("config"))
home::home_dir().map(|h| h.join(".kube").join("config"))
}

#[cfg(test)]
Expand Down