Class: EnjuLibrary::SetupGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- EnjuLibrary::SetupGenerator
- Defined in:
- lib/generators/enju_library/setup/setup_generator.rb
Instance Method Summary collapse
Instance Method Details
#copy_setup_files ⇒ Object
5 6 7 8 9 10 11 |
# File 'lib/generators/enju_library/setup/setup_generator.rb', line 5 def copy_setup_files directory("db/fixtures", "db/fixtures/enju_library") return if file == 'fixture' inject_into_file 'app/controllers/application_controller.rb', " include EnjuLibrary::Controller\n", after: "include EnjuLeaf::Controller\n" append_to_file("app/models/user.rb", "Item.include(EnjuLibrary::EnjuItem)\n") end |