class PuppetDebugger::InputResponderPlugin

Attributes

debugger[RW]

Public Class Methods

command_completion(_buffer_words) click to toggle source

@param buffer_words [Array] a array of words the user has typed in @return Array - an array of words that will help the user with word completion By default this returns an empty array, your plugin can chose to override this method in order to provide the user with a list of key words based on the user's input

# File lib/puppet-debugger/input_responder_plugin.rb, line 45
def self.command_completion(_buffer_words)
  []
end
command_group() click to toggle source

@return [String] the name of the command group the plugin is in

# File lib/puppet-debugger/input_responder_plugin.rb, line 32
def self.command_group
  self::COMMAND_GROUP
end
command_words() click to toggle source

@return [Array] an array of words the user can call the command with

# File lib/puppet-debugger/input_responder_plugin.rb, line 18
def self.command_words
  self::COMMAND_WORDS
end
details() click to toggle source

@return [Hash] a has of all the details of the plugin

# File lib/puppet-debugger/input_responder_plugin.rb, line 37
def self.details
  { words: command_words, summary: summary, group: command_group }
end
execute(args = [], debugger) click to toggle source

@param args [Array] - an array of arguments to pass to the plugin command @param debugger PuppetDebugger::Cli - an instance of the PuppetDebugger::Cli object @return the output of the plugin command

# File lib/puppet-debugger/input_responder_plugin.rb, line 52
def self.execute(args = [], debugger)
  instance.debugger = debugger
  instance.run(args)
end
summary() click to toggle source

@return [String] a summary of the plugin

# File lib/puppet-debugger/input_responder_plugin.rb, line 27
def self.summary
  self::SUMMARY
end

Public Instance Methods

modules_paths() click to toggle source
# File lib/puppet-debugger/input_responder_plugin.rb, line 22
def modules_paths
  debugger.puppet_environment.full_modulepath
end
puppet_debugger_lib_dir() click to toggle source

this is the lib directory of this gem in order to load any puppet functions from this gem we need to add the lib path of this gem

# File lib/puppet-debugger/input_responder_plugin.rb, line 66
def puppet_debugger_lib_dir
  File.expand_path(File.join(File.dirname(File.dirname(File.dirname(__FILE__))), 'lib'))
end
run(args = []) click to toggle source

@param args [Array] - an array of arguments to pass to the plugin command @return the output of the plugin command

# File lib/puppet-debugger/input_responder_plugin.rb, line 59
def run(args = [])
  raise NotImplementedError
end