You are here

function migrate_devel_drush_command_alter in Migrate Devel 8

Same name and namespace in other branches
  1. 8.2 migrate_devel.drush.inc \migrate_devel_drush_command_alter()

Implements hook_drush_command_alter().

File

./migrate_devel.drush.inc, line 30
File for Drush Integration.

Code

function migrate_devel_drush_command_alter(&$command) {
  $cmd = $command['command'];
  if ($cmd === 'migrate-import' || $cmd === 'migrate-status') {

    // Reset all migrations
    if (drush_get_option('migrate-debug')) {
      migrate_devel_rebuild_migrations();
    }
  }
}