Merge pull request #7245 from dawidd6/pr-pull-tap

pr-pull: allow to specify tap
This commit is contained in:
Mike McQuaid 2020-03-31 11:43:54 +01:00 committed by GitHub
commit bf74abcc62
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 5 deletions

View File

@ -37,7 +37,9 @@ module Homebrew
flag "--artifact=",
description: "Download artifacts with the specified name (default: bottles)."
flag "--bintray-org=",
description: "Upload to the specified Bintray organisation."
description: "Upload to the specified Bintray organisation (default: homebrew)."
flag "--tap=",
description: "Target repository tap (default: homebrew/core)."
switch :verbose
switch :debug
min_named 1
@ -106,12 +108,12 @@ module Homebrew
workflow = args.workflow || "tests.yml"
artifact = args.artifact || "bottles"
tap = Tap.fetch(args.tap || "homebrew/core")
args.named.each do |arg|
arg = "#{CoreTap.instance.default_remote}/pull/#{arg}" if arg.to_i.positive?
arg = "#{tap.default_remote}/pull/#{arg}" if arg.to_i.positive?
url_match = arg.match HOMEBREW_PULL_OR_COMMIT_URL_REGEX
_, user, repo, pr = *url_match
tap = Tap.fetch(user, repo) if repo.match?(HOMEBREW_OFFICIAL_REPO_PREFIXES_REGEX)
odie "Not a GitHub pull request: #{arg}" unless pr
check_branch tap.path, "master"

View File

@ -910,7 +910,9 @@ repository.
* `--artifact`:
Download artifacts with the specified name (default: bottles).
* `--bintray-org`:
Upload to the specified Bintray organisation.
Upload to the specified Bintray organisation (default: homebrew).
* `--tap`:
Target repository tap (default: homebrew/core).
### `prof` *`command`*

View File

@ -1164,7 +1164,11 @@ Download artifacts with the specified name (default: bottles)\.
.
.TP
\fB\-\-bintray\-org\fR
Upload to the specified Bintray organisation\.
Upload to the specified Bintray organisation (default: homebrew)\.
.
.TP
\fB\-\-tap\fR
Target repository tap (default: homebrew/core)\.
.
.SS "\fBprof\fR \fIcommand\fR"
Run Homebrew with the Ruby profiler, e\.g\. \fBbrew prof readall\fR\.