From 0656a30f18cdb52a25a3a9aebfe51f2588572358 Mon Sep 17 00:00:00 2001 From: William Woodruff Date: Fri, 21 Jun 2024 12:35:01 -0400 Subject: [PATCH] formula_installer: fix gh bootstrap cycle Signed-off-by: William Woodruff --- Library/Homebrew/formula_installer.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Library/Homebrew/formula_installer.rb b/Library/Homebrew/formula_installer.rb index 48510ff628471..1d00a0a0d4ec9 100644 --- a/Library/Homebrew/formula_installer.rb +++ b/Library/Homebrew/formula_installer.rb @@ -1256,7 +1256,9 @@ def downloader sig { void } def pour - if Homebrew::EnvConfig.verify_attestations? && formula.tap&.core_tap? + # We skip `gh` to avoid a bootstrapping cycle, in the off-chance a user attempts + # to explicitly `brew install gh` without already having a version for bootstrapping. + if Homebrew::EnvConfig.verify_attestations? && formula.tap&.core_tap? && formula.name != "gh" ohai "Verifying attestation for #{formula.name}" begin Homebrew::Attestation.check_core_attestation formula.bottle