Class: BB8::CLI
- Inherits:
-
Object
- Object
- BB8::CLI
- Defined in:
- lib/bb8/cli.rb
Class Method Summary collapse
Class Method Details
.call(*arguments) ⇒ Object
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/bb8/cli.rb', line 2 def self.call(*arguments) environments = Dir['*'].select { |file| File.directory? file } case arguments.first when 'init' BB8::Commands::InitialiseProject.call arguments[1] when 'version' BB8::Commands::Version.call when 'environment' BB8::Commands::InitialiseEnvironment.call arguments[1], arguments[2] when *environments BB8::Commands::Terraform.call(*arguments) else BB8::Commands::Help.call end end |