From a76bb8806ae506a5d11c88a3dbd6377d6c4bc1ec Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Thu, 25 Jan 2018 16:22:58 -0800 Subject: [PATCH] Call non-git beta builds simply x.y.z-beta We can't use git commands to compute a prerelease version when we're building from a source tarball, or if git is otherwise unavailable. We'll just call such builds `x.y.z-beta`, without a prerelease. --- src/bootstrap/lib.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/bootstrap/lib.rs b/src/bootstrap/lib.rs index 3738828a4baed..9fbbbb0278a04 100644 --- a/src/bootstrap/lib.rs +++ b/src/bootstrap/lib.rs @@ -776,7 +776,11 @@ impl Build { fn release(&self, num: &str) -> String { match &self.config.channel[..] { "stable" => num.to_string(), - "beta" => format!("{}-beta.{}", num, self.beta_prerelease_version()), + "beta" => if self.rust_info.is_git() { + format!("{}-beta.{}", num, self.beta_prerelease_version()) + } else { + format!("{}-beta", num) + }, "nightly" => format!("{}-nightly", num), _ => format!("{}-dev", num), }