Class: Cms::ModuleInstallation
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- Cms::ModuleInstallation
- Includes:
- InstallationActions
- Defined in:
- lib/cms/module_installation.rb
Overview
Provides a base class for Module installation generators.
Usage:
require 'cms/module_installation'
class MyModule::InstallGenerator < Cms::ModuleInstallation
add_migrations_directory_to_source_root __FILE__
end
Class Method Summary collapse
-
.add_migrations_directory_to_source_root(generator_file_object) ⇒ Object
This will be relative to the gem e.g.
Methods included from InstallationActions
Class Method Details
.add_migrations_directory_to_source_root(generator_file_object) ⇒ Object
This will be relative to the gem e.g. add_migrations_directory_to_source_root __FILE__
17 18 19 |
# File 'lib/cms/module_installation.rb', line 17 def self.add_migrations_directory_to_source_root(generator_file_object) source_root File.('../../../../../db/migrate/', generator_file_object) end |