Class: PuppetDebugger::InputResponders::Set
Constant Summary
collapse
- COMMAND_WORDS =
%w(set :set)
- SUMMARY =
'Set the a puppet debugger config'
- COMMAND_GROUP =
:scope
- KEYWORDS =
%w(node loglevel)
- LOGLEVELS =
%w(debug info)
Instance Attribute Summary
#debugger
Class Method Summary
collapse
Instance Method Summary
collapse
command_group, command_words, details, execute, #modules_paths, #puppet_debugger_lib_dir, summary
Class Method Details
.command_completion(buffer_words) ⇒ Object
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
# File 'lib/plugins/puppet-debugger/input_responders/set.rb', line 11
def self.command_completion(buffer_words)
next_word = buffer_words.shift
case next_word
when 'loglevel'
if buffer_words.count > 0
LOGLEVELS.grep(/^#{Regexp.escape(buffer_words.first)}/)
else
LOGLEVELS
end
when 'debug', 'info','node'
[]
when nil
%w(node loglevel)
else
KEYWORDS.grep(/^#{Regexp.escape(next_word)}/)
end
end
|
Instance Method Details
#run(args = []) ⇒ Object
29
30
31
|
# File 'lib/plugins/puppet-debugger/input_responders/set.rb', line 29
def run(args = [])
handle_set(args)
end
|