Class: MigrationButton::LegacyImplementation
- Inherits:
-
Object
- Object
- MigrationButton::LegacyImplementation
- Includes:
- RunnerHelper
- Defined in:
- lib/migration_button/runner.rb
Instance Method Summary collapse
Instance Method Details
#migrate ⇒ Object
66 67 68 69 70 |
# File 'lib/migration_button/runner.rb', line 66 def migrate capture_output do ActiveRecord::Migrator.migrate(migrations_paths) end end |
#migrations_status ⇒ Object
62 63 64 |
# File 'lib/migration_button/runner.rb', line 62 def migrations_status ActiveRecord::Migrator.migrations_status(migrations_paths) end |
#rollback ⇒ Object
72 73 74 75 76 |
# File 'lib/migration_button/runner.rb', line 72 def rollback capture_output do ActiveRecord::Migrator.rollback(migrations_paths) end end |
#run(direction, version) ⇒ Object
78 79 80 81 82 |
# File 'lib/migration_button/runner.rb', line 78 def run(direction, version) capture_output do ActiveRecord::Migrator.run(direction.intern, migrations_paths, version.to_i) end end |