test-bot: remove support for legacy Homebrew repo. (#287)
We're not really getting any more PRs here and this code makes this file harder to follow and refactor.
This commit is contained in:
parent
9edb1a7a87
commit
f946693b56
@ -11,8 +11,6 @@
|
|||||||
# --junit: Generate a JUnit XML test results file.
|
# --junit: Generate a JUnit XML test results file.
|
||||||
# --no-bottle: Run brew install without --build-bottle.
|
# --no-bottle: Run brew install without --build-bottle.
|
||||||
# --keep-old: Run brew bottle --keep-old to build new bottles for a single platform.
|
# --keep-old: Run brew bottle --keep-old to build new bottles for a single platform.
|
||||||
# --legacy Build formula from legacy Homebrew/legacy-homebrew repo.
|
|
||||||
# (TODO remove it when it's not longer necessary)
|
|
||||||
# --HEAD: Run brew install with --HEAD.
|
# --HEAD: Run brew install with --HEAD.
|
||||||
# --local: Ask Homebrew to write verbose logs under ./logs/ and set HOME to ./home/.
|
# --local: Ask Homebrew to write verbose logs under ./logs/ and set HOME to ./home/.
|
||||||
# --tap=<tap>: Use the git repository of the given tap.
|
# --tap=<tap>: Use the git repository of the given tap.
|
||||||
@ -342,11 +340,7 @@ module Homebrew
|
|||||||
# the right commit to BrewTestBot.
|
# the right commit to BrewTestBot.
|
||||||
unless travis_pr
|
unless travis_pr
|
||||||
diff_start_sha1 = current_sha1
|
diff_start_sha1 = current_sha1
|
||||||
if ARGV.include?("--legacy")
|
|
||||||
test "brew", "pull", "--clean", "--legacy", @url
|
|
||||||
else
|
|
||||||
test "brew", "pull", "--clean", @url
|
test "brew", "pull", "--clean", @url
|
||||||
end
|
|
||||||
diff_end_sha1 = current_sha1
|
diff_end_sha1 = current_sha1
|
||||||
end
|
end
|
||||||
@short_url = @url.gsub("https://github.com/", "")
|
@short_url = @url.gsub("https://github.com/", "")
|
||||||
@ -789,7 +783,6 @@ module Homebrew
|
|||||||
ENV["HUDSON_COOKIE"] = nil
|
ENV["HUDSON_COOKIE"] = nil
|
||||||
|
|
||||||
ARGV << "--verbose"
|
ARGV << "--verbose"
|
||||||
ARGV << "--legacy" if ENV["UPSTREAM_BOTTLE_LEGACY"]
|
|
||||||
|
|
||||||
bottles = Dir["#{jenkins}/jobs/#{job}/configurations/axis-version/*/builds/#{id}/archive/*.bottle*.*"]
|
bottles = Dir["#{jenkins}/jobs/#{job}/configurations/axis-version/*/builds/#{id}/archive/*.bottle*.*"]
|
||||||
return if bottles.empty?
|
return if bottles.empty?
|
||||||
@ -810,14 +803,9 @@ module Homebrew
|
|||||||
safe_system "brew", "update"
|
safe_system "brew", "update"
|
||||||
|
|
||||||
if pr
|
if pr
|
||||||
if ARGV.include?("--legacy")
|
|
||||||
pull_pr = "https://github.com/Homebrew/legacy-homebrew/pull/#{pr}"
|
|
||||||
safe_system "brew", "pull", "--clean", "--legacy", pull_pr
|
|
||||||
else
|
|
||||||
pull_pr = "https://github.com/#{tap.user}/homebrew-#{tap.repo}/pull/#{pr}"
|
pull_pr = "https://github.com/#{tap.user}/homebrew-#{tap.repo}/pull/#{pr}"
|
||||||
safe_system "brew", "pull", "--clean", pull_pr
|
safe_system "brew", "pull", "--clean", pull_pr
|
||||||
end
|
end
|
||||||
end
|
|
||||||
|
|
||||||
json_files = Dir.glob("*.bottle.json")
|
json_files = Dir.glob("*.bottle.json")
|
||||||
system "brew", "bottle", "--merge", "--write", *json_files
|
system "brew", "bottle", "--merge", "--write", *json_files
|
||||||
|
Loading…
x
Reference in New Issue
Block a user