test-bot: don't repeat creating Bintray packages.
This commit is contained in:
parent
579f288bd2
commit
bf76b71fe9
@ -729,6 +729,8 @@ module Homebrew
|
|||||||
"bottles"
|
"bottles"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
formula_packaged = {}
|
||||||
|
|
||||||
Dir.glob("*.bottle*.tar.gz") do |filename|
|
Dir.glob("*.bottle*.tar.gz") do |filename|
|
||||||
# Skip taps for now until we're using Bintray for Homebrew/homebrew
|
# Skip taps for now until we're using Bintray for Homebrew/homebrew
|
||||||
next if tap
|
next if tap
|
||||||
@ -736,14 +738,17 @@ module Homebrew
|
|||||||
formula = bottle_filename_formula_name filename
|
formula = bottle_filename_formula_name filename
|
||||||
existing_bottle = existing_bottles[formula]
|
existing_bottle = existing_bottles[formula]
|
||||||
|
|
||||||
repo_url = "https://api.bintray.com/packages/homebrew/#{repo}"
|
unless formula_packaged[formula]
|
||||||
package_url = "#{repo_url}/#{formula}"
|
repo_url = "https://api.bintray.com/packages/homebrew/#{repo}"
|
||||||
unless system "curl", "--silent", "--fail", "--output", "/dev/null", package_url
|
package_url = "#{repo_url}/#{formula}"
|
||||||
safe_system "curl", "--silent", "--fail",
|
unless system "curl", "--silent", "--fail", "--output", "/dev/null", package_url
|
||||||
"-u#{bintray_user}:#{bintray_key}",
|
safe_system "curl", "--silent", "--fail",
|
||||||
"-H", "Content-Type: application/json",
|
"-u#{bintray_user}:#{bintray_key}",
|
||||||
"-d", "{\"name\":\"#{formula}\"}", repo_url
|
"-H", "Content-Type: application/json",
|
||||||
puts
|
"-d", "{\"name\":\"#{formula}\"}", repo_url
|
||||||
|
puts
|
||||||
|
end
|
||||||
|
formula_packaged[formula] = true
|
||||||
end
|
end
|
||||||
|
|
||||||
content_url = "https://api.bintray.com/content/homebrew/#{repo}/#{formula}/#{version}/#{filename}"
|
content_url = "https://api.bintray.com/content/homebrew/#{repo}/#{formula}/#{version}/#{filename}"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user