Class: PicoPhone::Rails::ExtractedPhoneNumbersGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- PicoPhone::Rails::ExtractedPhoneNumbersGenerator
- Includes:
- Rails::Generators::Migration
- Defined in:
- lib/generators/pico_phone/rails/extracted_phone_numbers/extracted_phone_numbers_generator.rb
Overview
Invoked as rails generate pico_phone:rails:extracted_phone_numbers.
Creates the migration for the table extract_phone_numbers_from ..., persist: true needs -- this is never run automatically, since a
gem shouldn't silently add tables to an app's schema.
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.next_migration_number(dirname) ⇒ String
20 21 22 |
# File 'lib/generators/pico_phone/rails/extracted_phone_numbers/extracted_phone_numbers_generator.rb', line 20 def self.next_migration_number(dirname) ::ActiveRecord::Generators::Base.next_migration_number(dirname) end |
Instance Method Details
#create_migration_file ⇒ void
This method returns an undefined value.
25 26 27 28 29 30 |
# File 'lib/generators/pico_phone/rails/extracted_phone_numbers/extracted_phone_numbers_generator.rb', line 25 def create_migration_file migration_template( "create_pico_phone_rails_extracted_phone_numbers.rb.tt", "db/migrate/create_pico_phone_rails_extracted_phone_numbers.rb" ) end |