mirror of
https://github.com/rust-lang/rust.git
synced 2025-06-07 12:48:30 +00:00
Rollup merge of #140394 - Kobzol:git-test-self-contained, r=jieyouxu
Make bootstrap git tests more self-contained Based on https://stackoverflow.com/a/67512433/1107768. Fixes: https://github.com/rust-lang/rust/issues/140387 r? ```@jieyouxu```
This commit is contained in:
commit
ec2dad74a8
@ -129,6 +129,9 @@ impl GitCtx {
|
|||||||
|
|
||||||
fn git_cmd(&self) -> Command {
|
fn git_cmd(&self) -> Command {
|
||||||
let mut cmd = Command::new("git");
|
let mut cmd = Command::new("git");
|
||||||
|
cmd.env("GIT_CONFIG_NOSYSTEM", "1");
|
||||||
|
cmd.env("GIT_CONFIG_SYSTEM", "/tmp/nonexistent");
|
||||||
|
cmd.env("GIT_CONFIG_GLOBAL", "/tmp/nonexistent");
|
||||||
cmd.current_dir(&self.dir);
|
cmd.current_dir(&self.dir);
|
||||||
cmd
|
cmd
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user