Class: Augmentor::Generators::AugmentGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- Augmentor::Generators::AugmentGenerator
- Includes:
- Rails::Generators::Migration
- Defined in:
- lib/generators/augmentor/augment_generator.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.next_migration_number(path) ⇒ Object
14 15 16 |
# File 'lib/generators/augmentor/augment_generator.rb', line 14 def self.next_migration_number(path) ActiveRecord::Generators::Base.next_migration_number(path) end |
Instance Method Details
#copy_migration ⇒ Object
18 19 20 |
# File 'lib/generators/augmentor/augment_generator.rb', line 18 def copy_migration migration_template 'augment_migration.rb', "db/migrate/add_#{extension_class.underscore.singularize}_as_augmentor_to_#{augmented_class.underscore.singularize}.rb" end |