Pass args.verbose? to Bintray.

This commit is contained in:
Markus Reiter 2020-08-02 02:47:38 +02:00
parent 51ff5eb401
commit 2dce2ace2c
3 changed files with 5 additions and 4 deletions

View File

@ -13,8 +13,9 @@ class Bintray
"#<Bintray: org=#{@bintray_org}>"
end
def initialize(org: "homebrew")
def initialize(org: "homebrew", verbose: false)
@bintray_org = org
@verbose = verbose
raise UsageError, "Must set a Bintray organisation!" unless @bintray_org
@ -32,7 +33,7 @@ class Bintray
end
curl(*args, url,
show_output: Homebrew.args.verbose?,
show_output: @verbose,
secrets: @bintray_key)
end

View File

@ -31,7 +31,7 @@ module Homebrew
bintray_org = args.bintray_org || "homebrew"
bintray_repo = args.bintray_repo || "mirror"
bintray = Bintray.new(org: bintray_org)
bintray = Bintray.new(org: bintray_org, verbose: args.verbose?)
args.formulae.each do |formula|
mirror_url = bintray.mirror_formula(formula, repo: bintray_repo, publish_package: !args.no_publish?)

View File

@ -49,7 +49,7 @@ module Homebrew
args = pr_upload_args.parse
bintray_org = args.bintray_org || "homebrew"
bintray = Bintray.new(org: bintray_org)
bintray = Bintray.new(org: bintray_org, verbose: args.verbose?)
json_files = Dir["*.json"]
odie "No JSON files found in the current working directory" if json_files.empty?