aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorMike McQuaid2014-10-16 21:42:53 +0100
committerMike McQuaid2014-10-16 21:42:55 +0100
commit358fd0ca19ea65e82577a1ff58f51793a9e9b56f (patch)
tree1ba521ccda06b2b7cc59a4264e384871a0f9e23b /Library
parentd1ab9fc6825a1918f68fd1cb7f57f8f933e654c5 (diff)
downloadbrew-358fd0ca19ea65e82577a1ff58f51793a9e9b56f.tar.bz2
brew-test-bot: use Jenkins PR plugin provided URL.
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/cmd/test-bot.rb15
1 files changed, 2 insertions, 13 deletions
diff --git a/Library/Homebrew/cmd/test-bot.rb b/Library/Homebrew/cmd/test-bot.rb
index 81d8c4687..f2d28a21e 100644
--- a/Library/Homebrew/cmd/test-bot.rb
+++ b/Library/Homebrew/cmd/test-bot.rb
@@ -222,7 +222,7 @@ module Homebrew
# Use Jenkins environment variables if present.
if no_args? and ENV['GIT_PREVIOUS_COMMIT'] and ENV['GIT_COMMIT'] \
- and not ENV['ghprbPullId']
+ and not ENV['ghprbPullLink']
diff_start_sha1 = shorten_revision ENV['GIT_PREVIOUS_COMMIT']
diff_end_sha1 = shorten_revision ENV['GIT_COMMIT']
test "brew", "update" if current_branch == "master"
@@ -233,18 +233,7 @@ module Homebrew
end
# Handle Jenkins pull request builder plugin.
- if ENV['ghprbPullId'] and ENV['GIT_URL']
- git_url = ENV['GIT_URL']
- git_match = git_url.match %r{.*github.com[:/](\w+/\w+).*}
- if git_match
- github_repo = git_match[1]
- pull_id = ENV['ghprbPullId']
- @url = "https://github.com/#{github_repo}/pull/#{pull_id}"
- @hash = nil
- else
- puts "Invalid 'ghprbPullId' environment variable value!"
- end
- end
+ @url = ENV['ghprbPullLink'] if ENV['ghprbPullLink']
if no_args?
if diff_start_sha1 == diff_end_sha1 or \