Dependency#to_formula and associated helpers
This commit is contained in:
parent
a569261a9b
commit
e9e16fefa9
@ -169,6 +169,14 @@ class Dependency
|
||||
def hash
|
||||
name.hash
|
||||
end
|
||||
|
||||
def to_formula
|
||||
Formula.factory(name)
|
||||
end
|
||||
|
||||
def requested?
|
||||
ARGV.formulae.include?(to_formula) rescue false
|
||||
end
|
||||
end
|
||||
|
||||
# A base class for non-formula requirements needed by formulae.
|
||||
|
@ -77,10 +77,6 @@ class Formula
|
||||
installed_prefix.children.length > 0 rescue false
|
||||
end
|
||||
|
||||
def explicitly_requested?
|
||||
ARGV.formulae.include?(self) rescue false
|
||||
end
|
||||
|
||||
def linked_keg
|
||||
HOMEBREW_REPOSITORY/'Library/LinkedKegs'/@name
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user