Exception: Tomo::Runtime::UnknownTaskError
- Defined in:
- lib/tomo/runtime/unknown_task_error.rb
Instance Attribute Summary collapse
-
#known_tasks ⇒ Object
Returns the value of attribute known_tasks.
-
#unknown_task ⇒ Object
Returns the value of attribute unknown_task.
Instance Method Summary collapse
Methods inherited from Error
Methods included from Colors
Instance Attribute Details
#known_tasks ⇒ Object
Returns the value of attribute known_tasks.
6 7 8 |
# File 'lib/tomo/runtime/unknown_task_error.rb', line 6 def known_tasks @known_tasks end |
#unknown_task ⇒ Object
Returns the value of attribute unknown_task.
6 7 8 |
# File 'lib/tomo/runtime/unknown_task_error.rb', line 6 def unknown_task @unknown_task end |
Instance Method Details
#to_console ⇒ Object
8 9 10 11 12 13 14 15 16 17 |
# File 'lib/tomo/runtime/unknown_task_error.rb', line 8 def to_console error = <<~ERROR #{yellow(unknown_task)} is not a recognized task. To see a list of all available tasks, run #{blue('tomo tasks')}. ERROR sugg = spelling_suggestion || missing_plugin_suggestion error += sugg if sugg error end |