class Configuration extends Configuration (View source)

Methods

__construct(bool $registerMigrations = true)

Construct a migration configuration object.

registerPreviousMigratedVersions()

This is a stupid requirement, but basically, we grab the lowest version number in our system database migrations table, and we loop through all migrations in our file system and for any of those LOWER than the lowest one in the table, we can assume they are included in this migration. We then manually insert these rows into the SystemDatabaseMigrations table so Doctrine isn't stupid and attempt to apply them.

Details

__construct(bool $registerMigrations = true)

Construct a migration configuration object.

Parameters

bool $registerMigrations

set to true to load the currently available migrations

registerPreviousMigratedVersions()

This is a stupid requirement, but basically, we grab the lowest version number in our system database migrations table, and we loop through all migrations in our file system and for any of those LOWER than the lowest one in the table, we can assume they are included in this migration. We then manually insert these rows into the SystemDatabaseMigrations table so Doctrine isn't stupid and attempt to apply them.