Skip to content

Commit

Permalink
fix(xtask): use canonical cargo_home location
Browse files Browse the repository at this point in the history
  • Loading branch information
mkroening committed Jan 3, 2025
1 parent 1a7e6a3 commit d99e982
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
10 changes: 10 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions xtask/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ edition = "2024"
anyhow = "1.0"
clap = { version = "4", features = ["derive"] }
goblin = { version = "0.9", default-features = false, features = ["archive", "elf32", "elf64", "std"] }
home = "0.5"
sysinfo = "0.33"
ureq = "2"
wait-timeout = "0.2"
Expand Down
2 changes: 1 addition & 1 deletion xtask/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ fn sanitize(cmd: &str) -> Command {
let exe = format!("{cmd}{}", env::consts::EXE_SUFFIX);
// On windows, the userspace toolchain ends up in front of the rustup proxy in $PATH.
// To reach the rustup proxy nonetheless, we explicitly query $CARGO_HOME.
let mut cargo_home = PathBuf::from(env::var_os("CARGO_HOME").unwrap());
let mut cargo_home = home::cargo_home().unwrap();
cargo_home.push("bin");
cargo_home.push(&exe);
if cargo_home.exists() {
Expand Down

0 comments on commit d99e982

Please sign in to comment.