Class: ConfigGet
Instance Attribute Summary
Attributes inherited from Command
#desc, #name
Instance Method Summary
collapse
Methods inherited from Command
#add_arg, #add_cmd, #add_flow, #add_flow_from_usage, #add_input, #add_option, #add_options, #command_name?, #flow_passes_parse, #flow_passes_preconditions, #get_args_used, #init, #initialize, #option_help_string, #run, #show_help, #show_help_option
Constructor Details
This class inherits a constructor from Command
Instance Method Details
#create_args ⇒ Object
33
34
35
|
# File 'lib/clui_config.rb', line 33
def create_args
add_arg("param", "name of configuration parameter", /[-a-zA-Z]+/)
end
|
#create_flows ⇒ Object
37
38
39
|
# File 'lib/clui_config.rb', line 37
def create_flows
add_flow_from_usage("<param>")
end
|
#execute(args, ignore) ⇒ Object
41
42
43
44
|
# File 'lib/clui_config.rb', line 41
def execute(args, ignore)
handler = ConfigHandler.new
puts handler.get(args["param"])
end
|