Method: Metior::Report#copy_assets
- Defined in:
- lib/metior/report.rb
permalink #copy_assets(target_dir) ⇒ Object (private)
Copies the assets coming with this report to the given target directory
This will copy the contents of the images
, javascript
and
stylesheets
directories inside the report's path into the target
directory.
126 127 128 129 130 131 132 133 134 135 |
# File 'lib/metior/report.rb', line 126 def copy_assets(target_dir) FileUtils.mkdir_p target_dir %w{images javascripts stylesheets}.map do |type| File.join(self.class.path, type) end.each do |src| next unless File.directory? src FileUtils.cp_r src, target_dir end end |