Sha256: 5f5ec3ddb56b9960331df08402c313760329de04eab8c345b83dde38234b3403

Contents?: true

Size: 809 Bytes

Versions: 20

Compression:

Stored size: 809 Bytes

Contents

module Alchemy
  module Devise
    module Generators
      class InstallGenerator < Rails::Generators::Base
        desc "Installs Alchemy Devise based authentication into your app."
        source_root File.expand_path('templates', File.dirname(__FILE__))

        def copy_devise_config
          template 'devise.rb.tt', 'config/initializers/devise.rb'
        end

        def add_migrations
          run 'bundle exec rake alchemy_devise:install:migrations'
        end

        def run_migrations
          run 'bundle exec rake db:migrate'
        end

        def append_assets
          insert_into_file "vendor/assets/stylesheets/alchemy/admin/all.css",
            "\n *= require alchemy/admin/alchemy-devise",
            after: " *= require alchemy/admin"
        end
      end
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
alchemy-devise-6.2.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-6.1.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-6.0.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-5.1.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-5.0.1 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-5.0.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.6.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.5.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.4.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.3.1 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.3.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.2.1 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.2.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.1.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.1.0.beta lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-4.0.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-3.6.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-3.5.0 lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-3.5.0.beta lib/generators/alchemy/devise/install/install_generator.rb
alchemy-devise-3.4.0 lib/generators/alchemy/devise/install/install_generator.rb