Class: TerraformLandscape::CLI
- Inherits:
-
Object
- Object
- TerraformLandscape::CLI
- Includes:
- Commander::Methods
- Defined in:
- lib/terraform_landscape/cli.rb
Overview
Command line application interface.
Instance Method Summary collapse
-
#initialize(output) ⇒ CLI
constructor
A new instance of CLI.
-
#run(_args) ⇒ Integer
Parses the given command line arguments and executes appropriate logic based on those arguments.
Constructor Details
#initialize(output) ⇒ CLI
Returns a new instance of CLI.
8 9 10 |
# File 'lib/terraform_landscape/cli.rb', line 8 def initialize(output) @output = output end |
Instance Method Details
#run(_args) ⇒ Integer
Parses the given command line arguments and executes appropriate logic based on those arguments.
18 19 20 21 22 23 24 25 26 27 |
# File 'lib/terraform_landscape/cli.rb', line 18 def run(_args) program :name, 'Terraform Landscape' program :version, VERSION program :description, 'Pretty-print your Terraform plan output' define_commands run! 0 # OK end |