Skip to content

Commit

Permalink
Merge pull request #12770 from carlocab/deprecated-dependencies
Browse files Browse the repository at this point in the history
formula_auditor: audit for deprecated dependencies
  • Loading branch information
carlocab authored Jul 30, 2022
2 parents 4f02c5d + 7c7a92e commit e217fd3
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Library/Homebrew/formula_auditor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,13 @@ def audit_deps
EOS
end

if dep_f.deprecated? && !formula.deprecated? && !formula.disabled?
problem <<~EOS
Dependency '#{dep.name}' is deprecated but has un-deprecated dependents. Either
un-deprecate '#{dep.name}' or deprecate it and all of its dependents.
EOS
end

# we want to allow uses_from_macos for aliases but not bare dependencies
if self.class.aliases.include?(dep.name) && spec.uses_from_macos_names.exclude?(dep.name)
problem "Dependency '#{dep.name}' is an alias; use the canonical name '#{dep.to_formula.full_name}'."
Expand Down

0 comments on commit e217fd3

Please sign in to comment.