Expose bottle details on the formula object
Fixes Homebrew/homebrew#36032.
This commit is contained in:
parent
8b793c6ab3
commit
af1e9a9610
@ -365,7 +365,7 @@ module Homebrew
|
||||
dependents -= @formulae
|
||||
dependents = dependents.map {|d| Formulary.factory(d)}
|
||||
|
||||
testable_dependents = dependents.select {|d| d.test_defined? && d.stable.bottled? }
|
||||
testable_dependents = dependents.select { |d| d.test_defined? && d.bottled? }
|
||||
|
||||
formula = Formulary.factory(formula_name)
|
||||
installed_gcc = false
|
||||
|
@ -147,10 +147,20 @@ class Formula
|
||||
active_spec == head
|
||||
end
|
||||
|
||||
# @private
|
||||
def bottled?
|
||||
active_spec.bottled?
|
||||
end
|
||||
|
||||
# @private
|
||||
def bottle_specification
|
||||
active_spec.bottle_specification
|
||||
end
|
||||
|
||||
# The Bottle object for the currently active {SoftwareSpec}.
|
||||
# @private
|
||||
def bottle
|
||||
Bottle.new(self, active_spec.bottle_specification) if active_spec.bottled?
|
||||
Bottle.new(self, bottle_specification) if bottled?
|
||||
end
|
||||
|
||||
# The homepage for the software.
|
||||
|
@ -78,7 +78,7 @@ class FormulaVersions
|
||||
map = Hash.new { |h, k| h[k] = [] }
|
||||
rev_list(branch) do |rev|
|
||||
formula_at_revision(rev) do |f|
|
||||
bottle = f.stable.bottle_specification
|
||||
bottle = f.bottle_specification
|
||||
unless bottle.checksums.empty?
|
||||
map[f.pkg_version] << bottle.revision
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user