Module: Commands::CommandMixin::ClassMethods
- Defined in:
- lib/gdsh/command_mixin.rb
Overview
Every ‘useful’ Command class should override the following (except terminal?)
Instance Method Summary collapse
- #command_name ⇒ Object
- #description ⇒ Object
- #function ⇒ Object
- #parameters ⇒ Object
- #terminal? ⇒ Boolean
Instance Method Details
#command_name ⇒ Object
24 25 26 |
# File 'lib/gdsh/command_mixin.rb', line 24 def command_name '' end |
#description ⇒ Object
36 37 38 39 |
# File 'lib/gdsh/command_mixin.rb', line 36 def description (command_name + parameters + ":\n ").colorize(:green) + function.colorize(:yellow) end |
#function ⇒ Object
28 29 30 |
# File 'lib/gdsh/command_mixin.rb', line 28 def function '' end |
#parameters ⇒ Object
32 33 34 |
# File 'lib/gdsh/command_mixin.rb', line 32 def parameters '' end |
#terminal? ⇒ Boolean
41 42 43 |
# File 'lib/gdsh/command_mixin.rb', line 41 def terminal? false end |