Library/Homebrew/dev-cmd/pull.rb
# Publishes the current bottle files for a given formula to Bintray
Publishes the current bottle files for a given formula to Bintray
Publishes the current bottle files for a given formula to Bintray
def publish_bottle_file_on_bintray(f, bintray_org, creds)
    repo = Utils::Bottles::Bintray.repository(f.tap)
    package = Utils::Bottles::Bintray.package(f.name)
    info = FormulaInfoFromJson.lookup(f.full_name)
    if info.nil?
      raise "Failed publishing bottle: failed reading formula info for #{f.full_name}"
    end
    unless info.bottle_info_any
      opoo "No bottle defined in formula #{package}"
      return false
    end
    version = info.pkg_version
    ohai "Publishing on Bintray: #{package} #{version}"
    curl "--write-out", '\n', "--silent", "--fail",
         "--user", "#{creds[:user]}:#{creds[:key]}", "--request", "POST",
         "--header", "Content-Type: application/json",
         "--data", '{"publish_wait_for_secs": 0}',
         "https://api.bintray.com/content/#{bintray_org}/#{repo}/#{package}/#{version}/publish"
    true
  rescue => e
    raise unless @args.warn_on_publish_failure?
    onoe e
    false
  end
def publish_bottle_file_on_bintray ( f , bintray_org , creds ) repo = Utils :: Bottles :: Bintray . repository ( f . tap ) package = Utils :: Bottles :: Bintray . package ( f . name ) info = FormulaInfoFromJson . lookup ( f . full_name ) if info . nil? raise "Failed publishing bottle: failed reading formula info for #{f.full_name}" end unless info . bottle_info_any opoo "No bottle defined in formula #{package}" return false end version = info . pkg_version ohai "Publishing on Bintray: #{package} #{version}" curl "--write-out" , '\n' , "--silent" , "--fail" , "--user" , "#{creds[:user]}:#{creds[:key]}" , "--request" , "POST" , "--header" , "Content-Type: application/json" , "--data" , '{"publish_wait_for_secs": 0}' , "https://api.bintray.com/content/#{bintray_org}/#{repo}/#{package}/#{version}/publish" true rescue => e raise unless @args . warn_on_publish_failure? onoe e false end
Publishes the current bottle files for a given formula to Bintray
Publishes the current bottle files for a given formula to Bintray
f
bintray_org
creds