php bin/console doctrine:migrations:version

Manually add and delete migration versions from the version table.

Usage

doctrine:migrations:version [--add] [--delete] [--all] [--range-from [RANGE-FROM]] [--range-to [RANGE-TO]] [--configuration [CONFIGURATION]] [--db-configuration [DB-CONFIGURATION]] [--db DB] [--em EM] [--shard SHARD] [--] [<version>]

Arguments

version   The version to add or delete. 

Options

      --add                Add the specified version. 
      --delete             Delete the specified version. 
      --all                Apply to all the versions. 
      --range-from         Apply from specified version. 
      --range-to           Apply to specified version. 
      --configuration      The path to a migrations configuration file. 
      --db-configuration   The path to a database connection configuration file. 
      --db                 The database connection to use for this command. 
      --em                 The entity manager to use for this command. 
      --shard              The shard connection to use for this command. 

Help

The doctrine:migrations:version command allows you to manually add, delete or synchronize migration versions from the version table:

    bin/console doctrine:migrations:version YYYYMMDDHHMMSS --add

If you want to delete a version you can use the --delete option:

    bin/console doctrine:migrations:version YYYYMMDDHHMMSS --delete

If you want to synchronize by adding or deleting all migration versions available in the version table you can use the --all option:

    bin/console doctrine:migrations:version --add --all
    bin/console doctrine:migrations:version --delete --all

If you want to synchronize by adding or deleting some range of migration versions available in the version table you can use the --range-from/--range-to option:

    bin/console doctrine:migrations:version --add --range-from=YYYYMMDDHHMMSS --range-to=YYYYMMDDHHMMSS
    bin/console doctrine:migrations:version --delete --range-from=YYYYMMDDHHMMSS --range-to=YYYYMMDDHHMMSS

You can also execute this command without a warning message which you need to interact with:

    bin/console doctrine:migrations:version --no-interaction