Skip to content

Releases: bizley/yii2-migration

4.4.1

05 Sep 15:46
ab28e05
Compare
Choose a tag to compare

Code cleaning and removing unnecessary docs,

4.4.0

10 Oct 17:14
dcb956f
Compare
Choose a tag to compare

Added new action sql allowing to extract SQL statements from the given migration file. Usage examples:

  • yii migration/sql migration_name
  • yii migration/sql migration_name up
  • yii migration/sql migration_name down

4.3.1

20 Feb 10:11
9abf721
Compare
Choose a tag to compare
  • Fixed order in which updating statements are rendered in the migration.
  • Used safeUp() instead of up() and safeDown() instead of down() in the migration template to match changes in default Yii behavior.

Thank you, @naduvko for reporting these.

4.3.0

16 Oct 19:45
8e79918
Compare
Choose a tag to compare
  • When multiple migrations are generated they are not saved with additional _n_ stamp (when n is the number of the next migration) anymore. Instead they are saved with just the timestamp that is not repeated for other migrations in the batch. Thanks to that it is safe to run migrate/mark, migrate/to, and similar Yii commands with such migrations. In case there are possible timestamp collisions with existing migrations user will get a warning first.
  • Added leeway (lw) option to add seconds to the starting timestamp for migrations generation.
  • Fixed issue with foreign key autoindex generated for MySQL update migrations comparison.

Many thanks to @karolls for reporting these cases.

4.2.0

10 Jun 10:04
35607a3
Compare
Choose a tag to compare
  • Added fileMode option to set the file permissions for generated migrations (int|string|null, default null, expects integer value like 0777 or integerish string convertable to integer).
  • Added fileOwnership option to set the file ownership for generated migrations (string|int|array<int|string, int|string>|null, default null, can be integer user id, string user name, string user:group combination, string user: or :group only, or array with [user, group] or ['user' => user, 'group' => group] data).
  • Changing file permission and group is done through Yii 2.0.43 FileHelper::changeOwnership() or the internal fallback in case of older Yii versions.
  • Refactored some code a bit.
  • Added more tests.
  • Improved mutation score.

4.1.4

15 Feb 09:55
39208d7
Compare
Choose a tag to compare
  • Yii's autoloader is not required to be pre-wired to an app anymore.
  • Fixed bug with not reusing DB connection for updates.

4.1.3

19 Dec 14:40
5a56ba7
Compare
Choose a tag to compare

Ensured MySQL 8 compatibility.

4.1.2

27 Oct 14:44
d853115
Compare
Choose a tag to compare

Fixed bug with handling renamed table migration.

3.6.6

03 Oct 12:57
34e1fc6
Compare
Choose a tag to compare

v4 suggested.

2.9.6

03 Oct 12:56
4a72223
Compare
Choose a tag to compare

v4 suggested.