aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd/test-bot.rb
diff options
context:
space:
mode:
authorXu Cheng2015-12-07 14:11:04 +0800
committerXu Cheng2015-12-09 16:56:59 +0800
commit2c25303949a9fa091868cbdd42fd4ff4877869fc (patch)
treeef4127caea10735397ae530022213c526d77150b /Library/Homebrew/cmd/test-bot.rb
parent5b435db3bfc48d8bb41a5773cf6d7ae8970a55e4 (diff)
downloadbrew-2c25303949a9fa091868cbdd42fd4ff4877869fc.tar.bz2
remove unnecessary tap_args
It's now handled by Tap.fetch
Diffstat (limited to 'Library/Homebrew/cmd/test-bot.rb')
-rw-r--r--Library/Homebrew/cmd/test-bot.rb17
1 files changed, 13 insertions, 4 deletions
diff --git a/Library/Homebrew/cmd/test-bot.rb b/Library/Homebrew/cmd/test-bot.rb
index 498b8444d..2c5ef7f7f 100644
--- a/Library/Homebrew/cmd/test-bot.rb
+++ b/Library/Homebrew/cmd/test-bot.rb
@@ -37,20 +37,29 @@ module Homebrew
def resolve_test_tap
tap = ARGV.value("tap")
- return Tap.fetch(*tap_args(tap)) if tap
+ if tap
+ tap = Tap.fetch(tap)
+ return tap unless tap.core_formula_repository?
+ end
if ENV["UPSTREAM_BOT_PARAMS"]
bot_argv = ENV["UPSTREAM_BOT_PARAMS"].split " "
bot_argv.extend HomebrewArgvExtension
tap = bot_argv.value("tap")
- return Tap.fetch(*tap_args(tap)) if tap
+ if tap
+ tap = Tap.fetch(tap)
+ return tap unless tap.core_formula_repository?
+ end
end
if git_url = ENV["UPSTREAM_GIT_URL"] || ENV["GIT_URL"]
# Also can get tap from Jenkins GIT_URL.
url_path = git_url.sub(%r{^https?://github\.com/}, "").chomp("/")
- HOMEBREW_TAP_ARGS_REGEX =~ url_path
- return Tap.fetch($1, $3) if $1 && $3 && $3 != "homebrew"
+ begin
+ tap = Tap.fetch(tap)
+ return tap unless tap.core_formula_repository?
+ rescue
+ end
end
# return nil means we are testing core repo.