Update pull request regex name to include commits.
This commit is contained in:
parent
a886a1b3e3
commit
bec7ff9807
@ -21,7 +21,7 @@ ARGV.named.each do|arg|
|
||||
if arg.to_i > 0
|
||||
url = 'https://github.com/mxcl/homebrew/pull/' + arg
|
||||
else
|
||||
url_match = arg.match HOMEBREW_PULL_URL_REGEX
|
||||
url_match = arg.match HOMEBREW_PULL_OR_COMMIT_URL_REGEX
|
||||
unless url_match
|
||||
ohai 'Ignoring URL:', "Not a GitHub pull request or commit: #{arg}"
|
||||
next
|
||||
|
||||
@ -106,7 +106,7 @@ class Test
|
||||
@url = nil
|
||||
@formulae = []
|
||||
|
||||
url_match = argument.match HOMEBREW_PULL_URL_REGEX
|
||||
url_match = argument.match HOMEBREW_PULL_OR_COMMIT_URL_REGEX
|
||||
formula = Formula.factory argument rescue FormulaUnavailableError
|
||||
git "rev-parse --verify #{argument} &>/dev/null"
|
||||
if $?.success?
|
||||
|
||||
@ -92,7 +92,7 @@ end
|
||||
require 'metafiles'
|
||||
FORMULA_META_FILES = Metafiles.new
|
||||
ISSUES_URL = "https://github.com/mxcl/homebrew/wiki/troubleshooting"
|
||||
HOMEBREW_PULL_URL_REGEX = 'https:\/\/github.com\/(\w+)\/homebrew(-\w+)?\/(pull\/(\d+)|commit\/\w{4,40})'
|
||||
HOMEBREW_PULL_OR_COMMIT_URL_REGEX = 'https:\/\/github.com\/(\w+)\/homebrew(-\w+)?\/(pull\/(\d+)|commit\/\w{4,40})'
|
||||
|
||||
require 'compat' unless ARGV.include? "--no-compat" or ENV['HOMEBREW_NO_COMPAT']
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user