Sha256: 7aa0013f9e7f5ca6fe14fda1dd9910e2e2c1d929e725420b586c664f2ffc65a0

Contents?: true

Size: 631 Bytes

Versions: 5

Compression:

Stored size: 631 Bytes

Contents

module Aureus

  module Generators

    class DeviseViewsGenerator < Rails::Generators::Base

      desc 'generates aureus compliant devise haml views with aureus helpers and i18n files'
      source_root File.expand_path('../templates', __FILE__)
      argument :folder, type: :string, default: 'devise'

      def generate
        target = "app/views/#{folder}"
        directory 'devise', target do |content|
          content.gsub '{{{folder}}}', folder
        end
        #Dir[target + '/**/*.haml'].each do |file|
          #gsub_file file, '{{{folder}}}', folder, verbose: false
        #end
      end

    end

  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
aureus-2.1.4 lib/generators/aureus/devise_views/devise_views_generator.rb
aureus-2.1.3 lib/generators/aureus/devise_views/devise_views_generator.rb
aureus-2.1.2 lib/generators/aureus/devise_views/devise_views_generator.rb
aureus-2.1.1 lib/generators/aureus/devise_views/devise_views_generator.rb
aureus-2.1.0 lib/generators/aureus/devise_views/devise_views_generator.rb