Class | Chef::Knife::SubcommandLoader
In: | lib/chef/knife/core/subcommand_loader.rb
Parent: | Object

### Methods

find_subcommands_via_dirglob find_subcommands_via_rubygems gem_and_builtin_subcommands load_commands new site_subcommands subcommand_files

### Constants

CHEF_FILE_IN_GEM | = | /chef-[\d]+\.[\d]+\.[\d]+/
CURRENT_CHEF_GEM | = | /chef-#{Regexp.escape(Chef::VERSION)}/

### Attributes

chef_config_dir | [R] |
env | [R] |

### Public Class methods

new(chef_config_dir, env=ENV)

### Public Instance methods

find_subcommands_via_dirglob()
find_subcommands_via_rubygems()
gem_and_builtin_subcommands()

Returns a Hash of paths to knife commands built-in to chef, or installed via gem. If rubygems is not installed, falls back to globbing the knife directory. The Hash is of the form {"relative/path" => "/absolute/path"}

load_commands()

Load all the sub-commands

site_subcommands()

Returns an Array of paths to knife commands located in chef_config_dir/plugins/knife/ and ~/.chef/plugins/knife/

subcommand_files()

[Validate]