Class: Evergreen::Cli
- Inherits:
-
Object
- Object
- Evergreen::Cli
- Defined in:
- lib/evergreen/cli.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.execute(argv) ⇒ Object
3 4 5 |
# File 'lib/evergreen/cli.rb', line 3 def self.execute(argv) new.execute(argv) end |
Instance Method Details
#execute(argv) ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/evergreen/cli.rb', line 7 def execute(argv) command = argv.shift root = File.(argv.shift || '.', Dir.pwd) case command when "serve" Evergreen::Suite.new(root).serve return true when "run" return Evergreen::Suite.new(root).run else puts "no such command '#{command}'" return false end end |