Module: Shellissimo::DSL::ClassMethods

Defined in:
lib/shellissimo/dsl.rb

Instance Method Summary collapse

Instance Method Details

#add_command(command) ⇒ Object



36
37
38
39
40
41
# File 'lib/shellissimo/dsl.rb', line 36

def add_command(command)
  new_commands = (commands << command)
  define_singleton_method :commands do
    new_commands
  end
end

#commandsCommandsCollection

Returns a list of defined commands.

Returns:



32
33
34
# File 'lib/shellissimo/dsl.rb', line 32

def commands
  CommandsCollection.new
end