aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew
diff options
context:
space:
mode:
authorMatt Torok2013-03-05 18:02:22 -0800
committerAdam Vandenberg2013-03-05 19:43:12 -0800
commit5f2f6a35dd94acc701641105c01ff0142c7d9b14 (patch)
tree290e2dbb9bbd1c36f5016ae6d7c12cd56f4db41b /Library/Homebrew
parente714a47c10c35bffd8de2d9e703db9d8c9e6d0eb (diff)
downloadbrew-5f2f6a35dd94acc701641105c01ff0142c7d9b14.tar.bz2
Added '--installed' option to `deps` command.
When deps command is passed this option, it will only show the dependencies for the installed forumas. This option overrides the '--all' option. Closes Homebrew/homebrew#18276. Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library/Homebrew')
-rw-r--r--Library/Homebrew/cmd/deps.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/Library/Homebrew/cmd/deps.rb b/Library/Homebrew/cmd/deps.rb
index 7e426f91f..9e6d450f3 100644
--- a/Library/Homebrew/cmd/deps.rb
+++ b/Library/Homebrew/cmd/deps.rb
@@ -9,7 +9,11 @@ end
module Homebrew extend self
def deps
- if ARGV.include? '--all'
+ if ARGV.include? '--installed'
+ Formula.installed.each do |f|
+ puts "#{f.name}: #{f.deps*' '}"
+ end
+ elsif ARGV.include? '--all'
Formula.each do |f|
puts "#{f.name}: #{f.deps*' '}"
end