Sha256: c8cd46b8691fd0aa0dafb5e4694cefab961a1f85c9f6b64f18f460493d44b975

Contents?: true

Size: 561 Bytes

Versions: 23

Compression:

Stored size: 561 Bytes

Contents

module Virgo
  class AssetsGenerator < Rails::Generators::Base
    source_root File.expand_path('../../../../..', __FILE__)

    def copy_views
      Dir["#{engine_root}/app/assets/**/*"].reject { |f|
        f.include?('admin') ||
        f.include?('tinymce')
      }.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

    def engine_root
      File.expand_path('../../../../..', __FILE__)
    end
  end
end

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
virgo-0.3.17 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.16 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.15 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.14 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.13 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.12 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.11 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.10 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.9 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.8 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.7 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.6 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.4 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.3 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.2 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3.1 lib/generators/virgo/assets/assets_generator.rb
virgo-0.3 lib/generators/virgo/assets/assets_generator.rb
virgo-0.2.9 lib/generators/virgo/assets/assets_generator.rb
virgo-0.2.8 lib/generators/virgo/assets/assets_generator.rb
virgo-0.2.7 lib/generators/virgo/assets/assets_generator.rb