diff options
| author | Jack Nagel | 2013-01-13 19:51:19 -0600 |
|---|---|---|
| committer | Jack Nagel | 2013-01-13 21:01:15 -0600 |
| commit | e629f14d56b803ffbc7f3470175f2b021a8816eb (patch) | |
| tree | a2a68e1157263a5a7761f43702933af926157ab7 /Library/Homebrew/cmd | |
| parent | 2d445d54b5110e03b6a089fed25865f1d02bfed4 (diff) | |
| download | brew-e629f14d56b803ffbc7f3470175f2b021a8816eb.tar.bz2 | |
Remove <=> from Dependency interface
It is important that dep equality corresponds to the name attribute, but
we may want to use the Comparable interface to sort them by installation
order in the future. Code that needs to sort them alphabetically should
just use sort_by.
Diffstat (limited to 'Library/Homebrew/cmd')
| -rw-r--r-- | Library/Homebrew/cmd/deps.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Library/Homebrew/cmd/deps.rb b/Library/Homebrew/cmd/deps.rb index a26dca03c..b26030082 100644 --- a/Library/Homebrew/cmd/deps.rb +++ b/Library/Homebrew/cmd/deps.rb @@ -22,7 +22,9 @@ module Homebrew extend self end else raise FormulaUnspecifiedError if ARGV.named.empty? - all_deps = ARGV.formulae.map{ |f| ARGV.one? ? f.deps : f.recursive_deps }.intersection + all_deps = ARGV.formulae.map do |f| + ARGV.one? ? f.deps : f.recursive_deps + end.intersection.map(&:name) all_deps.sort! unless ARGV.include? "-n" puts all_deps end |
