extract: fix tap regex
This commit is contained in:
parent
8b1aaa957a
commit
52de3f9d8d
@ -101,9 +101,9 @@ module Homebrew
|
|||||||
def extract
|
def extract
|
||||||
args = extract_args.parse
|
args = extract_args.parse
|
||||||
|
|
||||||
if args.named.first =~ HOMEBREW_TAP_FORMULA_REGEX
|
if (match = args.named.first.match(HOMEBREW_TAP_FORMULA_REGEX))
|
||||||
name = Regexp.last_match(3).downcase
|
name = match[3].downcase
|
||||||
source_tap = Tap.fetch(Regexp.last_match(1), Regexp.last_match(2))
|
source_tap = Tap.fetch(match[1], match[2])
|
||||||
raise TapFormulaUnavailableError.new(source_tap, name) unless source_tap.installed?
|
raise TapFormulaUnavailableError.new(source_tap, name) unless source_tap.installed?
|
||||||
else
|
else
|
||||||
name = args.named.first.downcase
|
name = args.named.first.downcase
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user