From 4dc8e66074ac25ebbaffbdd1872febff9ac444c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20Ber=C3=A1nek?= Date: Thu, 18 Jul 2024 15:49:10 +0200 Subject: [PATCH] Allow a git command for getting the current branch in bootstrap to fail It can fail when in git is in detached HEAD mode. --- src/bootstrap/src/lib.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/bootstrap/src/lib.rs b/src/bootstrap/src/lib.rs index db1fa05a82c..a77c20067e6 100644 --- a/src/bootstrap/src/lib.rs +++ b/src/bootstrap/src/lib.rs @@ -535,6 +535,7 @@ impl Build { // even though that has no relation to the upstream for the submodule. let current_branch = helpers::git(Some(&self.src)) .capture_stdout() + .allow_failure() .run_always() .args(["symbolic-ref", "--short", "HEAD"]) .run(self)