Class: MGit::CommandManager
- Inherits:
-
Object
- Object
- MGit::CommandManager
- Defined in:
- lib/m-git/command_manager.rb
Class Method Summary collapse
- .[](cmd) ⇒ Object
- .class_with_command(cmd) ⇒ Object
-
.commands ⇒ Object
cmd generate.
- .register_command(cmd, cls) ⇒ Object
Class Method Details
.[](cmd) ⇒ Object
15 16 17 |
# File 'lib/m-git/command_manager.rb', line 15 def [](cmd) class_with_command(cmd) end |
.class_with_command(cmd) ⇒ Object
19 20 21 |
# File 'lib/m-git/command_manager.rb', line 19 def class_with_command(cmd) commands[cmd] end |
.commands ⇒ Object
cmd generate
7 8 9 |
# File 'lib/m-git/command_manager.rb', line 7 def commands @commands ||= {} end |
.register_command(cmd, cls) ⇒ Object
11 12 13 |
# File 'lib/m-git/command_manager.rb', line 11 def register_command(cmd, cls) commands[cmd] = cls end |