Skip to content

Commit

Permalink
Merge pull request #18350 from Homebrew/fail-when-no-longer-all-bottle
Browse files Browse the repository at this point in the history
dev-cmd/bottle: improve `:all` bottle handling
  • Loading branch information
MikeMcQuaid authored Sep 18, 2024
2 parents e220725 + f26530d commit 21bb3e1
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions Library/Homebrew/dev-cmd/bottle.rb
Original file line number Diff line number Diff line change
Expand Up @@ -743,6 +743,14 @@ def merge
tag_hashes.count > 1 &&
tag_hashes.uniq { |tag_hash| "#{tag_hash["cellar"]}-#{tag_hash["sha256"]}" }.count == 1

old_all_bottle = old_bottle_spec.tag?(Utils::Bottles.tag(:all))
if !all_bottle && old_all_bottle && !args.no_all_checks?
odie <<~ERROR
#{formula} should have an `:all` bottle but one cannot be created:
#{JSON.pretty_generate(tag_hashes)}
ERROR
end

bottle_hash["bottle"]["tags"].each do |tag, tag_hash|
cellar = tag_hash["cellar"]
cellar = cellar.to_sym if any_cellars.include?(cellar)
Expand Down

0 comments on commit 21bb3e1

Please sign in to comment.