brew/Library/Homebrew/cmd/missing.rb
Mike McQuaid 1f963267b6 Update Rubocop style.
Another look at the current Rubocop rules and how they fit with our
existing and desired future style. Almost all of these changes were
automatic. Split some rules between formulae/brew where brew doesn't
have millions of cases that need fixed.
2016-10-22 13:32:46 +01:00

27 lines
534 B
Ruby

#: * `missing` [<formulae>]:
#: Check the given <formulae> for missing dependencies. If no <formulae> are
#: given, check all installed brews.
require "formula"
require "tab"
require "diagnostic"
module Homebrew
module_function
def missing
return unless HOMEBREW_CELLAR.exist?
ff = if ARGV.named.empty?
Formula.installed
else
ARGV.resolved_formulae
end
Diagnostic.missing_deps(ff) do |name, missing|
print "#{name}: " if ff.size > 1
puts missing.join(" ")
end
end
end