Exception: TapFormulaOrCaskUnavailableError

Inherits:
FormulaOrCaskUnavailableError show all
Extended by:
T::Sig
Defined in:
exceptions.rb

Overview

Raised when a formula or cask in a specific tap is not available.

Instance Attribute Summary collapse

Attributes inherited from FormulaOrCaskUnavailableError

#name

Instance Method Summary collapse

Constructor Details

#initialize(tap, name) ⇒ TapFormulaOrCaskUnavailableError

Returns a new instance of TapFormulaOrCaskUnavailableError.



106
107
108
109
# File 'exceptions.rb', line 106

def initialize(tap, name)
  super "#{tap}/#{name}"
  @tap = tap
end

Instance Attribute Details

#tapObject (readonly)

Returns the value of attribute tap.



104
105
106
# File 'exceptions.rb', line 104

def tap
  @tap
end

Instance Method Details

#to_sString

Returns:



112
113
114
115
116
# File 'exceptions.rb', line 112

def to_s
  s = super
  s += "\nPlease tap it and then try again: brew tap #{tap}" unless tap.installed?
  s
end