Sha256: 4de082090a8760d94372e787df3155a86c0561bd28ee2c67fb52a618d73fc903

Contents?: true

Size: 677 Bytes

Versions: 29

Compression:

Stored size: 677 Bytes

Contents

require 'rails/generators/base'

class Configatron
  class InstallGenerator < ::Rails::Generators::Base #:nodoc:
    
    desc 'Generates configatron files for the default Rails environments.'
    
    def self.source_root
      @_configatron_source_root ||= File.expand_path(File.join(File.dirname(__FILE__), 'templates'))
    end
    
    def self.banner
      "rails generate configatron:install"
    end

    def copy_files
      template 'initializers/configatron.rb', 'config/initializers/configatron.rb'
      %w{defaults development production test}.each do |env|
        template "configatron/#{env}.rb", "config/configatron/#{env}.rb"
      end
    end
    
  end
end

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
configatron-4.5.1 lib/generators/configatron/install/install_generator.rb
configatron-4.5.0 lib/generators/configatron/install/install_generator.rb
configatron-4.4.1 lib/generators/configatron/install/install_generator.rb
configatron-4.4.0 lib/generators/configatron/install/install_generator.rb
configatron-4.3.0 lib/generators/configatron/install/install_generator.rb
configatron-4.2.1 lib/generators/configatron/install/install_generator.rb
configatron-4.2.0 lib/generators/configatron/install/install_generator.rb
configatron-4.1.1 lib/generators/configatron/install/install_generator.rb
configatron-4.1.0 lib/generators/configatron/install/install_generator.rb
configatron-4.0.3 lib/generators/configatron/install/install_generator.rb
configatron-4.0.2 lib/generators/configatron/install/install_generator.rb
configatron-4.0.1 lib/generators/configatron/install/install_generator.rb
configatron-4.0.0 lib/generators/configatron/install/install_generator.rb
configatron-3.2.0 lib/generators/configatron/install/install_generator.rb
configatron-3.1.3 lib/generators/configatron/install/install_generator.rb
configatron-3.1.2 lib/generators/configatron/install/install_generator.rb
configatron-3.1.1 lib/generators/configatron/install/install_generator.rb
configatron-3.1.0 lib/generators/configatron/install/install_generator.rb
configatron-3.0.2 lib/generators/configatron/install/install_generator.rb
configatron-3.0.1 lib/generators/configatron/install/install_generator.rb