diff options
| author | John Hawkinson | 2017-04-09 15:23:53 -0400 | 
|---|---|---|
| committer | John Hawkinson | 2017-04-09 15:23:53 -0400 | 
| commit | 971e53c001c06c66fab961c69951fa6c15459054 (patch) | |
| tree | ad74f680e50449c908c5d1fd9249ae2a617ac892 /Library/Homebrew/cmd/info.rb | |
| parent | 31ce953f6911f9ad2e64311b9e0237f448ff3559 (diff) | |
| download | brew-971e53c001c06c66fab961c69951fa6c15459054.tar.bz2 | |
info: Print reason for conflicts where available
Diffstat (limited to 'Library/Homebrew/cmd/info.rb')
| -rw-r--r-- | Library/Homebrew/cmd/info.rb | 8 | 
1 files changed, 6 insertions, 2 deletions
| diff --git a/Library/Homebrew/cmd/info.rb b/Library/Homebrew/cmd/info.rb index e7ad6821d..da8263287 100644 --- a/Library/Homebrew/cmd/info.rb +++ b/Library/Homebrew/cmd/info.rb @@ -123,8 +123,12 @@ module Homebrew      puts f.desc if f.desc      puts Formatter.url(f.homepage) if f.homepage -    conflicts = f.conflicts.map(&:name).sort! -    puts "Conflicts with: #{conflicts*", "}" unless conflicts.empty? +    conflicts = f.conflicts.map{ |f| +      f.name + +      if f.reason then " (because #{f.reason})" else "" end +    }.sort! +    msg="Conflicts with: " +    puts msg+conflicts*(",\n"+" "*msg.length) unless conflicts.empty?      kegs = f.installed_kegs.sort_by(&:version)      if kegs.empty? | 
