Method: Utilities::PuppetModule#create_tmp_module_path
- Defined in:
- lib/retrospec/plugins/v1/plugin/puppet_module.rb
#create_tmp_module_path(module_path) ⇒ Object
puts a symlink in that module directory that points back to the user supplied module path
103 104 105 106 107 108 109 110 111 |
# File 'lib/retrospec/plugins/v1/plugin/puppet_module.rb', line 103 def create_tmp_module_path(module_path) fail 'ModulePathNotFound' unless module_path path = File.join(tmp_modules_dir, module_dir_name) unless File.exist?(path) # only create if it doesn't already exist # create a link where source is the current repo and dest is /tmp/modules/module_name FileUtils.ln_s(module_path, path) end path end |