diff options
Diffstat (limited to 'Library/Homebrew/cmd')
| -rw-r--r-- | Library/Homebrew/cmd/tap-info.rb | 2 | ||||
| -rw-r--r-- | Library/Homebrew/cmd/tap.rb | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/Library/Homebrew/cmd/tap-info.rb b/Library/Homebrew/cmd/tap-info.rb index e05b9eb08..cd3f82109 100644 --- a/Library/Homebrew/cmd/tap-info.rb +++ b/Library/Homebrew/cmd/tap-info.rb @@ -48,7 +48,7 @@ module Homebrew info += "Not installed" end puts info - puts "From: #{tap.remote}" + puts "From: #{tap.remote.nil? ? "N/A" : tap.remote}" end end end diff --git a/Library/Homebrew/cmd/tap.rb b/Library/Homebrew/cmd/tap.rb index 3a0a1156b..43e47711e 100644 --- a/Library/Homebrew/cmd/tap.rb +++ b/Library/Homebrew/cmd/tap.rb @@ -14,10 +14,11 @@ module Homebrew end def install_tap user, repo, clone_target=nil - tap = Tap.new user, repo, clone_target + tap = Tap.new user, repo return false if tap.installed? ohai "Tapping #{tap}" - args = %W[clone #{tap.remote} #{tap.path}] + remote = clone_target || "https://github.com/#{tap.user}/homebrew-#{tap.repo}" + args = %W[clone #{remote} #{tap.path}] args << "--depth=1" unless ARGV.include?("--full") safe_system "git", *args |
