diff options
| author | Mike McQuaid | 2014-02-17 19:10:15 +0000 |
|---|---|---|
| committer | Mike McQuaid | 2014-02-17 19:10:15 +0000 |
| commit | 52f3c3b9e343f3fd7dbc860197595bed3e04dc5d (patch) | |
| tree | 2adb3bd9f0815ec33b6eedb59808430f33693c88 /Library | |
| parent | 7bdaa7ffe1cd837d0f2d6c5007907534b8aaeb0e (diff) | |
| download | brew-52f3c3b9e343f3fd7dbc860197595bed3e04dc5d.tar.bz2 | |
pull: tap if necessary.
Diffstat (limited to 'Library')
| -rwxr-xr-x | Library/Contributions/cmd/brew-pull.rb | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/Library/Contributions/cmd/brew-pull.rb b/Library/Contributions/cmd/brew-pull.rb index f7c8f7d3c..79ef9cb61 100755 --- a/Library/Contributions/cmd/brew-pull.rb +++ b/Library/Contributions/cmd/brew-pull.rb @@ -30,8 +30,11 @@ ARGV.named.each do|arg| url = url_match[0] end - if tap url - Dir.chdir HOMEBREW_REPOSITORY/"Library/Taps/#{url_match[1].downcase}-#{tap url}" + if tap_name = tap(url) + user = url_match[1].downcase + tap_dir = HOMEBREW_REPOSITORY/"Library/Taps/#{user}-#{tap_name}" + safe_system "brew", "tap", "#{user}/#{tap_name}" unless tap_dir.exist? + Dir.chdir tap_dir else Dir.chdir HOMEBREW_REPOSITORY end |
