aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/migration.rb
Commit message (Collapse)AuthorAgeFilesLines
* adding missed changekayvan2014-02-111-1/+1
|
* adding connection parameter to check_pending for migrationskayvan2014-02-111-5/+5
|
* activerecord: Initialize Migration with version from MigrationProxy.Dylan Thacker-Smith2014-01-061-1/+1
|
* Automatically maintain test database schemaJon Leighton2014-01-021-0/+13
| | | | | | | | | | | | | | * Move check from generated helper to test_help.rb, so that all applications can benefit * Rather than just raising when the test schema has pending migrations, try to load in the schema and only raise if there are pending migrations afterwards * Opt out of the check by setting config.active_record.maintain_test_schema = false * Deprecate db:test:* tasks. The test helper is now fully responsible for maintaining the test schema, so we don't need rake tasks for this. This is also a speed improvement since we're no longer reloading the test database on every call to "rake test".
* ActiveRecord migration exception message formattingJohn Joseph Bachir2013-12-031-8/+15
|
* Remove deprecated cattr_* requiresGenadi Samokovarov2013-12-031-1/+1
|
* Use `SchemaStatements#initialize_schema_migrations_table` instead of ↵Ryuta Kamizono2013-11-201-1/+1
| | | | `ActiveRecord::SchemaMigration.create_table`.
* Refer to Rails.env only when Rails is definedAkira Matsuda2013-11-111-1/+5
|
* Warnings removed for ruby trunkArun Agrawal2013-11-011-1/+1
| | | Same as 4d4ff531b8807ee88a3fc46875c7e76f613956fb
* Fix migration docs to use new remove_column semanticsPaul Nikitochkin2013-10-251-2/+2
| | | | Fixes: #12640
* Changing deprecation_horizon to be Rails 4.2wangjohn2013-08-241-1/+1
| | | | | Also, +ActiveRecord::Migrator.proper_table_name+ should actually have a deprecation horizon of Rails 4.2 (not 4.1).
* Making proper_table_name take in options.wangjohn2013-08-221-18/+40
| | | | | | | | | | | The options will specify the prefix and the suffix. Also, I'm moving the method to be an instance method on the +Migration+ instance. This makes more sense than being a class method on the +Migrator+ class because the only place that uses it is on a +Migration+ instance (in a method_missing hook). The logic for the Migrator shouldn't be doing any work to calculate the table name, it should be the Migration itself. Also made some small indentation fixes.
* Avoid "uninitialized constant ActiveRecord::PendingMigrationError::Rails"Akira Matsuda2013-07-291-1/+1
|
* rake -> bin/rakeSteve Klabnik2013-07-241-1/+1
|
* remove leftover if after deprecation removal (68563128).Yves Senn2013-07-041-4/+1
|
* Remove deprecated block filter from `ActiveRecord::Migrator#migrate`.Yves Senn2013-07-041-9/+1
|
* Remove deprecated String constructor from `ActiveRecord::Migrator`.Yves Senn2013-07-041-3/+0
|
* Fix Build. Changing constructor.Arun Agrawal2013-06-051-3/+3
|
* only check pending migrations if there are new filesAaron Patterson2013-06-051-2/+25
|
* Fix #10789. Now at last ::Logger doesn't support #silence method .kennyj2013-06-051-3/+1
|
* copy edits [ci skip]Vijay Dev2013-05-121-5/+1
|
* Added documentation for ActiveRecord::Base#next_migration_numberaditya-kapoor2013-05-091-0/+5
|
* Remove code duplicationNeeraj Singh2013-04-241-8/+9
|
* Improve the error messageRafael Mendonça França2013-04-191-1/+1
|
* Support transactions in Migrator.runbondarev2013-04-181-5/+12
|
* mark ReversibleBlockHelper as :nodoc: [ci skip]Francesco Rodriguez2013-04-041-1/+1
|
* Fixed typos in activerecordPrathamesh Sonpatki2013-03-271-1/+1
|
* Changed the call to .sort.last to .max when computing the migration version. Youwangjohn2013-03-191-1/+1
| | | | | do not actually need to sort everything (incurs more cost than just a simple max).
* Preserve magic comments and content encoding of copied migrations.OZAWA Sakuro2013-03-091-3/+12
| | | | | During insertion of "# This migration comes from ... " comment at the beginning of a migration, presence of magic comment was not considered.
* Fix changelog indent, remove self from method call in changelog/doc examplesCarlos Antonio da Silva2013-03-081-1/+2
| | | | [ci skip]
* transactions can be turned off per Migration.Yves Senn2013-03-051-7/+37
| | | | | | | | | | | Closes #9483. There are SQL Queries that can't run inside a transaction. Since the Migrator used to wrap all Migrations inside a transaction there was no way to run these queries within a migration. This patch adds `self.disable_ddl_transaction!` to the migration to turn transactions off when necessary.
* Use `silence` instead of `quietly` to silence the `CheckPending` middleware.Lucas Mazza2013-01-261-1/+1
| | | | | | | | `Kernel.quietly` silences `STDOUT` and `STDERR`, which is useless if the logger is writing to a file, while `AS::Logger#silence` swaps the logger level to `ERROR`. Related to #8820 and #8052.
* Fixes for PR [#8267]Marc-Andre Lafortune2012-12-221-1/+10
| | | | | | | | * Fix Migration#reversible by not using `transaction`. * Adapt mysql adapter to updated api for remove_column * Update test after aedcd683684d08eaf30623a4b48ce31a31426372
* Correctly shows RAILS_ENV=development even when ENV['RAILS_ENV'] is not set ↵Andy Lindeman2012-12-211-1/+1
| | | | | | (e.g., in Pow) * Fixes #8025
* Add Migration#reversible for reversible data operations [#8267]Marc-Andre Lafortune2012-12-211-0/+41
|
* Allow revert of whole migration [#8267]Marc-Andre Lafortune2012-12-211-3/+39
|
* Extract exec_migration [#8267]Marc-Andre Lafortune2012-12-211-11/+16
|
* Allow reverting of migration commands with Migration#revert [#8267]Marc-Andre Lafortune2012-12-211-25/+45
|
* recognize migrations, in folders containing numbers and 'rb'.Yves Senn2012-12-131-1/+1
| | | | Closes #8492
* Move to the schema-migrations-metadata branch.Jeremy Kemper2012-12-091-17/+7
| | | | | | | | | | | | | | | | | | | | | | | | Pending work on graceful app upgrades. Revert "Merge pull request #8439 from joshsusser/fixes" This reverts commit ce8ac39338f86388e70356b3a470b3ea443802ae, reversing changes made to b0e7b6f67c984d4b1502e801781ed75fad681633. Revert "Merge pull request #8431 from joshsusser/schemadump" This reverts commit 036d3e1c2b65c4b8cbd23de2e20ad67b9b756182, reversing changes made to 0c692f4d121792117b6a71e5ed590a31c3b9d12e. Revert "Merge branch 'joshsusser-master' into merge" This reverts commit 0c692f4d121792117b6a71e5ed590a31c3b9d12e, reversing changes made to 2e299fca715b083a60222a85e48f9d3b8dd8ce93. Conflicts: activerecord/CHANGELOG.md activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb activerecord/test/cases/schema_dumper_test.rb
* Add metadata to schema_migrationsJosh Susser2012-12-011-7/+17
| | | | | migrated_at: timestamp when migration run fingerprint: md5 hash of migration source name: filename without version or extension
* stop raising so many exceptionsAaron Patterson2012-11-071-1/+5
|
* Fixed grammar in migration pending error.Steve Klabnik2012-11-021-1/+1
|
* Make caller attribute in deprecation methods optionalAlexey Gaziev2012-10-301-1/+1
|
* Provide a call stack for deprecation warnings where needed.Nikita Afanasenko2012-10-291-3/+2
| | | | It's sometimes hard to quickly find where deprecated call was performed, especially in case of migrating between Rails versions. So this is an attempt to improve the call stack part of the warning message by providing caller explicitly.
* Don't log on pending migration check schneems2012-10-281-1/+3
| | | | | Conversation from: #6665 cc/ @rafaelfranca
* Fix missing typewriter tagLincoln Lee2012-10-081-1/+1
|
* fix example in Migration docs [ci skip]Francesco Rodriguez2012-09-301-1/+1
|
* add change_table transformation to Migration docs [ci skip]Francesco Rodriguez2012-09-301-16/+19
|
* Revert "Remove update_attribute."Rafael Mendonça França2012-08-251-2/+2
| | | | | | | | | | | This reverts commit a7f4b0a1231bf3c65db2ad4066da78c3da5ffb01. Conflicts: activerecord/lib/active_record/associations/has_one_association.rb activerecord/lib/active_record/persistence.rb activerecord/test/cases/base_test.rb activerecord/test/cases/dirty_test.rb activerecord/test/cases/timestamp_test.rb