Class: Imageomatic::InstallGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- Imageomatic::InstallGenerator
- Defined in:
- lib/generators/imageomatic/install/install_generator.rb
Instance Method Summary collapse
Instance Method Details
#copy_configuration_file ⇒ Object
16 17 18 |
# File 'lib/generators/imageomatic/install/install_generator.rb', line 16 def copy_configuration_file template "imageomatic.rb.tt", "config/initializers/imageomatic.rb" end |
#copy_layout ⇒ Object
12 13 14 |
# File 'lib/generators/imageomatic/install/install_generator.rb', line 12 def copy_layout copy_file "application.opengraph.erb", "app/views/layouts/application.opengraph.erb" end |
#include_controller_helper ⇒ Object
4 5 6 7 8 9 10 |
# File 'lib/generators/imageomatic/install/install_generator.rb', line 4 def include_controller_helper inject_into_file 'app/controllers/application_controller.rb', after: "class ApplicationController < ActionController::Base\n" do <<-'RUBY' include Imageomatic::Opengraph RUBY end end |