Skip to content

Commit 14f34e1

Browse files
committed
Fix benchsuite issue with newer versions of git
1 parent 1b77ac6 commit 14f34e1

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

benches/benchsuite/src/lib.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -127,9 +127,12 @@ impl Fixtures {
127127
fs::create_dir_all(&index).unwrap();
128128
git("init --bare");
129129
git("remote add origin https://github.com/rust-lang/crates.io-index-archive");
130+
// git 2.48.0 changed the behavior of setting HEAD, so let's just
131+
// force it to match crates.io-index-archive's default branch.
132+
git("symbolic-ref HEAD refs/heads/main");
130133
}
131134
git(&format!("fetch origin {}", CRATES_IO_COMMIT));
132-
git("branch -f master FETCH_HEAD");
135+
git("branch -f main FETCH_HEAD");
133136
}
134137

135138
/// This unpacks the compressed workspace skeletons into tmp/workspaces.

0 commit comments

Comments
 (0)