Sha256: abb5221970b891a87dc3aa63a1a0c4f11b468b260bbb63eab700c7ef5f4ad5cc
Contents?: true
Size: 706 Bytes
Versions: 7
Compression:
Stored size: 706 Bytes
Contents
module Ecm module Blog module Generators class InstallGenerator < Rails::Generators::Base desc 'Generates the initializer' source_root File.expand_path('../templates', __FILE__) attr_reader :base_controller_class_name def initialize(*args) super @base_controller_class_name = ENV.fetch('BASE_CONTROLLER_CLASS_NAME') { '::FrontendController' } end def generate_initializer template 'initializer.rb', 'config/initializers/ecm_blog.rb' end def generate_routes route File.read(File.join(File.expand_path('../templates', __FILE__), 'routes.source')) end end end end end
Version data entries
7 entries across 7 versions & 1 rubygems