Class: Rubysmith::CLI::Processors::Config
- Inherits:
-
Object
- Object
- Rubysmith::CLI::Processors::Config
- Defined in:
- lib/rubysmith/cli/processors/config.rb
Overview
Handles the Command Line Interface (CLI) configuration processing.
Instance Method Summary collapse
- #call(action) ⇒ Object
-
#initialize(configuration: CLI::Configuration::Loader::CLIENT, kernel: Kernel) ⇒ Config
constructor
A new instance of Config.
Constructor Details
#initialize(configuration: CLI::Configuration::Loader::CLIENT, kernel: Kernel) ⇒ Config
Returns a new instance of Config.
8 9 10 11 |
# File 'lib/rubysmith/cli/processors/config.rb', line 8 def initialize configuration: CLI::Configuration::Loader::CLIENT, kernel: Kernel @configuration = configuration @kernel = kernel end |
Instance Method Details
#call(action) ⇒ Object
13 14 15 16 17 18 19 |
# File 'lib/rubysmith/cli/processors/config.rb', line 13 def call action case action when :edit then edit when :view then view else fail StandardError, "Invalid configuration action: #{action}." end end |