diff options
Diffstat (limited to 'lib/leap_cli/config/manager.rb')
-rw-r--r-- | lib/leap_cli/config/manager.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/leap_cli/config/manager.rb b/lib/leap_cli/config/manager.rb index 7b3fb27..1831de7 100644 --- a/lib/leap_cli/config/manager.rb +++ b/lib/leap_cli/config/manager.rb @@ -20,6 +20,16 @@ module LeapCli def initialize @environments = {} # hash of `Environment` objects, keyed by name. + + # load macros and other custom ruby in provider base + platform_ruby_files = Dir[Path.provider_base + '/lib/*.rb'] + if platform_ruby_files.any? + $: << Path.provider_base + '/lib' + platform_ruby_files.each do |rb_file| + require rb_file + end + end + Config::Object.send(:include, LeapCli::Macro) end ## |