Exception: TapFormulaOrCaskUnavailableError

Inherits:
FormulaOrCaskUnavailableError show all
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

Methods inherited from FormulaOrCaskUnavailableError

#did_you_mean

Constructor Details

#initialize(tap, name) ⇒ TapFormulaOrCaskUnavailableError

Returns a new instance of TapFormulaOrCaskUnavailableError.



122
123
124
125
# File 'exceptions.rb', line 122

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

Instance Attribute Details

#tapObject (readonly)

Returns the value of attribute tap.



120
121
122
# File 'exceptions.rb', line 120

def tap
  @tap
end

Instance Method Details

#to_sString

Returns:



128
129
130
131
132
# File 'exceptions.rb', line 128

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