class Virgo::ViewsGenerator
Public Instance Methods
copy_views()
click to toggle source
# File lib/generators/virgo/views/views_generator.rb, line 5 def copy_views Dir["#{engine_root}/app/views/**/*"].reject { |f| f.include?('admin') || f.include?('shortcode_templates') }.each do |abs_path| relative_path = abs_path.gsub("#{engine_root}/", '') unless File.directory?(abs_path) copy_file relative_path, relative_path end end end
engine_root()
click to toggle source
# File lib/generators/virgo/views/views_generator.rb, line 18 def engine_root File.expand_path('../../../../..', __FILE__) end