Exception: Tomo::Configuration::UnknownPluginError
- Defined in:
- lib/tomo/configuration/unknown_plugin_error.rb
Instance Attribute Summary collapse
-
#gem_name ⇒ Object
Returns the value of attribute gem_name.
-
#known_plugins ⇒ Object
Returns the value of attribute known_plugins.
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
Methods inherited from Error
Methods included from Tomo::Colors
Instance Attribute Details
#gem_name ⇒ Object
Returns the value of attribute gem_name.
6 7 8 |
# File 'lib/tomo/configuration/unknown_plugin_error.rb', line 6 def gem_name @gem_name end |
#known_plugins ⇒ Object
Returns the value of attribute known_plugins.
6 7 8 |
# File 'lib/tomo/configuration/unknown_plugin_error.rb', line 6 def known_plugins @known_plugins end |
#name ⇒ Object
Returns the value of attribute name.
6 7 8 |
# File 'lib/tomo/configuration/unknown_plugin_error.rb', line 6 def name @name end |
Instance Method Details
#to_console ⇒ Object
8 9 10 11 12 13 14 15 16 17 |
# File 'lib/tomo/configuration/unknown_plugin_error.rb', line 8 def to_console error = <<~ERROR #{yellow(name)} is not a recognized plugin. ERROR sugg = Error::Suggestions.new(dictionary: known_plugins, word: name) error += sugg.to_console if sugg.any? error + gem_suggestion end |