Class: Questionable::Generators::InstallGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- Questionable::Generators::InstallGenerator
- Includes:
- Rails::Generators::Migration
- Defined in:
- lib/questionable.rb
Instance Method Summary collapse
Instance Method Details
#copy_migrations ⇒ Object
39 40 41 42 43 44 45 46 47 |
# File 'lib/questionable.rb', line 39 def copy_migrations filename = 'questionable_migration' if self.class.migration_exists?('db/migrate', filename) say_status('skipped', "Migration #{filename}.rb already exists") else migration_template "migrations/#{filename}.rb", "db/migrate/#{filename}.rb" end end |