Exception: TapFormulaUnavailableError
- Inherits:
-
FormulaUnavailableError
- Object
- RuntimeError
- FormulaOrCaskUnavailableError
- FormulaUnavailableError
- TapFormulaUnavailableError
- Defined in:
- exceptions.rb
Overview
Raised when a formula in a specific tap is unavailable.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#repo ⇒ Object
readonly
Returns the value of attribute repo.
-
#tap ⇒ Object
readonly
Returns the value of attribute tap.
-
#user ⇒ Object
readonly
Returns the value of attribute user.
Attributes inherited from FormulaUnavailableError
Attributes inherited from FormulaOrCaskUnavailableError
Instance Method Summary collapse
-
#initialize(tap, name) ⇒ TapFormulaUnavailableError
constructor
A new instance of TapFormulaUnavailableError.
-
#to_s ⇒ Object
Methods inherited from FormulaUnavailableError
Methods inherited from FormulaOrCaskUnavailableError
Constructor Details
#initialize(tap, name) ⇒ TapFormulaUnavailableError
Returns a new instance of TapFormulaUnavailableError.
223 224 225 226 227 228 |
# File 'exceptions.rb', line 223 def initialize(tap, name) @tap = tap @user = tap.user @repo = tap.repo super "#{tap}/#{name}" end |
Instance Attribute Details
#repo ⇒ Object (readonly)
Returns the value of attribute repo.
221 222 223 |
# File 'exceptions.rb', line 221 def repo @repo end |
#tap ⇒ Object (readonly)
Returns the value of attribute tap.
221 222 223 |
# File 'exceptions.rb', line 221 def tap @tap end |
#user ⇒ Object (readonly)
Returns the value of attribute user.
221 222 223 |
# File 'exceptions.rb', line 221 def user @user end |
Instance Method Details
#to_s ⇒ Object
230 231 232 233 234 |
# File 'exceptions.rb', line 230 def to_s s = super s += "\nPlease tap it and then try again: brew tap #{tap}" unless tap.installed? s end |