Class: Punt

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

Constant Summary collapse

CMDS =
[CmdInit.new,
        CmdDeploy.new,
        CmdRemote.new,
].sort { |first, second| first.name <=> second.name }

Class Method Summary collapse

Class Method Details

.cmd(argv) ⇒ Object



17
18
19
20
21
22
23
24
# File 'lib/punt.rb', line 17

def self.cmd(argv)
    first = argv.shift
    matching_cmd = find_cmd(first)

    usage and return unless matching_cmd

    matching_cmd.run(argv)
end