aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd/tap.rb
diff options
context:
space:
mode:
authorMax Howell2012-03-17 00:04:11 +0000
committerMax Howell2012-03-17 00:04:43 +0000
commitf15c64739316e7f48043ec79bcbd756a12a33495 (patch)
tree069c763ee83ee8fb3647ff98508a6b808d77669c /Library/Homebrew/cmd/tap.rb
parent6ee85cdc7759e326b53dcb969b60eb0d7da5dc35 (diff)
downloadhomebrew-f15c64739316e7f48043ec79bcbd756a12a33495.tar.bz2
Plain `brew tap` doesn't error if no Library/Taps
Fixes #10994.
Diffstat (limited to 'Library/Homebrew/cmd/tap.rb')
-rw-r--r--Library/Homebrew/cmd/tap.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/Library/Homebrew/cmd/tap.rb b/Library/Homebrew/cmd/tap.rb
index bfbc4a410..dcf308952 100644
--- a/Library/Homebrew/cmd/tap.rb
+++ b/Library/Homebrew/cmd/tap.rb
@@ -2,9 +2,10 @@ module Homebrew extend self
def tap
if ARGV.empty?
- (HOMEBREW_LIBRARY/"Taps").children.each do |tap|
+ tapd = HOMEBREW_LIBRARY/"Taps"
+ tapd.children.each do |tap|
puts tap.basename.sub('-', '/') if (tap/'.git').directory?
- end
+ end if tapd.directory?
else
install_tap(*tap_args)
end