Merge pull request #9052 from jonchang/deprecate-requirements-in-core
audit: deprecate requirements in core
This commit is contained in:
commit
0793644f62
@ -665,6 +665,23 @@ module RuboCop
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# This cop ensures that new formulae depending on Requirements are not introduced in homebrew/core.
|
||||||
|
class CoreRequirements < FormulaCop
|
||||||
|
def audit_formula(_node, _class_node, _parent_class_node, _body_node)
|
||||||
|
return if formula_tap != "homebrew-core"
|
||||||
|
|
||||||
|
if depends_on? :java
|
||||||
|
problem "Formulae in homebrew/core should depend on a versioned `openjdk` instead of :java"
|
||||||
|
end
|
||||||
|
|
||||||
|
if depends_on? :x11
|
||||||
|
problem "Formulae in homebrew/core should depend on specific X libraries instead of :x11"
|
||||||
|
end
|
||||||
|
|
||||||
|
problem ":osxfuse is deprecated in homebrew/core" if depends_on? :osxfuse
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
# This cop makes sure that shell command arguments are separated.
|
# This cop makes sure that shell command arguments are separated.
|
||||||
#
|
#
|
||||||
# @api private
|
# @api private
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user