Method: Inspec::Plugin::V2::Loader#initialize
- Defined in:
- lib/inspec/plugin/v2/loader.rb
#initialize(options = {}) ⇒ Loader
Returns a new instance of Loader.
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 |
# File 'lib/inspec/plugin/v2/loader.rb', line 14 def initialize( = {}) = @registry = Inspec::Plugin::V2::Registry.instance unless [:omit_user_plugins] @conf_file = Inspec::Plugin::V2::ConfigFile.new read_conf_file_into_registry end # Old-style (v0, v1) co-distributed plugins were called 'bundles' # and were located in lib/bundles detect_bundled_plugins unless [:omit_bundles] # New-style (v2) co-distributed plugins are in lib/plugins, # and may be safely loaded detect_core_plugins unless [:omit_core_plugins] # Train plugins aren't InSpec plugins (they don't use our API) # but InSpec CLI manages them. So, we have to wrap them a bit. accommodate_train_plugins end |