Class: FastExt::InstallGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- FastExt::InstallGenerator
- Defined in:
- lib/generators/fast_ext/install_generator.rb
Instance Method Summary collapse
- #copy_config_file ⇒ Object
- #copy_migrations ⇒ Object
- #insert_engine_routes ⇒ Object
- #remove_index_html ⇒ Object
- #show_readme ⇒ Object
Instance Method Details
#copy_config_file ⇒ Object
8 9 10 |
# File 'lib/generators/fast_ext/install_generator.rb', line 8 def copy_config_file template "fast_ext_config.erb", "config/initializers/fast_ext_config.rb" end |
#copy_migrations ⇒ Object
12 13 14 |
# File 'lib/generators/fast_ext/install_generator.rb', line 12 def copy_migrations rake("fast_ext:install:migrations") end |
#insert_engine_routes ⇒ Object
16 17 18 19 20 |
# File 'lib/generators/fast_ext/install_generator.rb', line 16 def insert_engine_routes route %( mount FastExt::Engine => '/fast_ext' ) end |
#remove_index_html ⇒ Object
22 23 24 |
# File 'lib/generators/fast_ext/install_generator.rb', line 22 def remove_index_html remove_file 'public/index.html' end |
#show_readme ⇒ Object
26 27 28 |
# File 'lib/generators/fast_ext/install_generator.rb', line 26 def show_readme readme '../USAGE' end |