Drush Migrate Inspect
Component ID
Component name
Component type
Maintenance status
Development status
Component security advisory coverage
Downloads
Component created
Component changed
Component body
Tools for inspecting records created by Drupal Migrate.
Usage
migrate-inspect-last
Open the last migrated item in a browser:
drush migrate-inspect-last MyMigration
drush mil MyMigrationmigrate-inspect-random
Open a random migrated item in a browser:
drush migrate-inspect-random MyMigration
drush mir MyMigrationmigrate-inspect-list
List the last 10 migrated items (source and destination ids):
drush migrate-inspect-list MyMigration
drush mils MyMigrationmigrate-inspect-source
List the source ID for a migrated item (101 is the destination id):
drush migrate-inspect-source MyMigration 101
drush mis MyMigration 101migrate-inspect-destination
List the destination ID for a migrated item (101 is the source id):
drush migrate-inspect-destination MyMigration 101
drush mid MyMigration 101Why?
Drupal's migrate module has Drush integration that gives you access to several pieces of a migrate workflow, but it doesn't give you an easy way to inspect things as you go. This extension is meant to make it easier to view migrated records/nodes/entities/whatnot as you move through the process. For example, currently if you are working on a migration you may:
- Write your migration code
- Run you migration, limiting to a single item
- View that item to see if your migration is working
Currently, to view that item you'd need to check out the migration map table yourself. Migrate Inspect can help with that by giving commands to view the last node, a random node (handy for spot checking when migrating lots of nodes), or listing/finding source or destination ids for specific cases you want to verify.
