audit: stop red-flagging devel-only
Currently the bot is failing certain devel-only formulae because it thinks having ` devel ` defined with an added ` head ` defined as well = a head-only formula. ``` ==> audit problems docker-machine: * Head-only (no stable download) ``` This is a pretty simple fix for that problem: ``` ==> brew style docker-machine 1 file inspected, no offenses detected ``` Closes Homebrew/homebrew#36197. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
This commit is contained in:
parent
8fc3c4c8e9
commit
40ddea637a
@ -359,6 +359,10 @@ class FormulaAuditor
|
|||||||
problem "Head-only (no stable download)"
|
problem "Head-only (no stable download)"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
if devel_only?(formula) && formula.tap != "homebrew/homebrew-devel-only"
|
||||||
|
problem "Devel-only (no stable download)"
|
||||||
|
end
|
||||||
|
|
||||||
%w[Stable Devel HEAD].each do |name|
|
%w[Stable Devel HEAD].each do |name|
|
||||||
next unless spec = formula.send(name.downcase)
|
next unless spec = formula.send(name.downcase)
|
||||||
|
|
||||||
@ -696,7 +700,11 @@ class FormulaAuditor
|
|||||||
end
|
end
|
||||||
|
|
||||||
def head_only?(formula)
|
def head_only?(formula)
|
||||||
formula.head && formula.stable.nil?
|
formula.head && formula.devel.nil? && formula.stable.nil?
|
||||||
|
end
|
||||||
|
|
||||||
|
def devel_only?(formula)
|
||||||
|
formula.devel && formula.stable.nil?
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user