As I understand the script is just replacing values in the wordpress database - there is no "migration" taking place anywhere - so this is kind of a misnomer.
migration is not just about replacing database values - it is a process of updating files and data and moving them around, also you want to be able to ROLLBACK on a migration error and certainly it makes sense to have versioning for beeing able to select to which state you want to revert. Please read about migration before using this term in a script that actually is just a web interface for a simple data replacement script. BTW you could do this with sed.