formula_creator: Remove tap accessor
This commit is contained in:
parent
2d9db76d61
commit
a7756bd303
@ -176,10 +176,11 @@ module Homebrew
|
|||||||
print "Formula name [#{stem}]: "
|
print "Formula name [#{stem}]: "
|
||||||
fc.name = __gets || stem
|
fc.name = __gets || stem
|
||||||
end
|
end
|
||||||
raise TapUnavailableError, fc.tap.name unless fc.tap.installed?
|
|
||||||
|
|
||||||
fc.url = args.named.first
|
fc.url = args.named.first
|
||||||
|
|
||||||
|
fc.verify
|
||||||
|
|
||||||
# Check for disallowed formula, or names that shadow aliases,
|
# Check for disallowed formula, or names that shadow aliases,
|
||||||
# unless --force is specified.
|
# unless --force is specified.
|
||||||
unless args.force?
|
unless args.force?
|
||||||
|
|||||||
@ -9,7 +9,6 @@ module Homebrew
|
|||||||
#
|
#
|
||||||
# @api private
|
# @api private
|
||||||
class FormulaCreator
|
class FormulaCreator
|
||||||
attr_reader :tap
|
|
||||||
attr_accessor :name
|
attr_accessor :name
|
||||||
|
|
||||||
sig {
|
sig {
|
||||||
@ -26,6 +25,11 @@ module Homebrew
|
|||||||
@head = head
|
@head = head
|
||||||
end
|
end
|
||||||
|
|
||||||
|
sig { void }
|
||||||
|
def verify
|
||||||
|
raise TapUnavailableError, @tap.name unless @tap.installed?
|
||||||
|
end
|
||||||
|
|
||||||
def url=(url)
|
def url=(url)
|
||||||
@url = url
|
@url = url
|
||||||
path = Pathname.new(url)
|
path = Pathname.new(url)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user