Class: Rbnotes::Commands::Command

Inherits:
Object
  • Object
show all
Defined in:
lib/rbnotes/commands.rb

Overview

The base class for a command class.

Instance Method Summary collapse

Instance Method Details

#descriptionObject

Short description of each command.



17
# File 'lib/rbnotes/commands.rb', line 17

def description; nil; end

#execute(args, conf) ⇒ Object

:call-seq:

execute(Array, Hash) -> nil

- Array: arguments for each command
- Hash : rbnotes configuration


26
27
28
# File 'lib/rbnotes/commands.rb', line 26

def execute(args, conf)
  Builtins.default_cmd.new.execute(args, conf)
end

#helpObject

Shows the help message for the command.



34
35
36
# File 'lib/rbnotes/commands.rb', line 34

def help
  Builtins::Usage.new.execute(nil, nil)
end