Class: Kitchen::Command::Base
- Inherits:
-
Object
- Object
- Kitchen::Command::Base
- Includes:
- Logging
- Defined in:
- lib/kitchen/command.rb
Overview
Base class for CLI commands.
Instance Method Summary collapse
-
#initialize(cmd_args, cmd_options, options = {}) ⇒ Base
constructor
Contstructs a new Command object.
Methods included from Logging
#banner, #debug, #error, #fatal, #info, #warn
Constructor Details
#initialize(cmd_args, cmd_options, options = {}) ⇒ Base
Contstructs a new Command object.
38 39 40 41 42 43 44 45 46 |
# File 'lib/kitchen/command.rb', line 38 def initialize(cmd_args, , = {}) @args = cmd_args @options = @action = .fetch(:action, nil) @help = .fetch(:help, -> { "No help provided" }) @config = .fetch(:config, nil) @loader = .fetch(:loader, nil) @shell = .fetch(:shell) end |