Skip to content

Commit

Permalink
Use home::cargo_home
Browse files Browse the repository at this point in the history
  • Loading branch information
sinkuu committed Oct 4, 2019
1 parent 20b7351 commit 248251b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions clippy_dev/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,5 @@ regex = "1"
lazy_static = "1.0"
shell-escape = "0.1"
walkdir = "2"
# FIXME: remove this once cargo issue #7475 is fixed
home = "0.5"
2 changes: 1 addition & 1 deletion clippy_dev/src/fmt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ fn project_root() -> Result<PathBuf, CliError> {
// Workaround for https://github.com/rust-lang/cargo/issues/7475.
// FIXME: replace `&bin_path("command")` with `"command"` once the issue is fixed
fn bin_path(bin: &str) -> String {
let mut p = PathBuf::from(std::env::var_os("CARGO_HOME").unwrap());
let mut p = home::cargo_home().unwrap();
p.push("bin");
p.push(bin);
p.display().to_string()
Expand Down

0 comments on commit 248251b

Please sign in to comment.