This is an extension of base Migration Command to provide functionality to have migrations in modules and apply/undo those migrations modules wise.
return array( ... ... 'commandMap' => array( 'migrate' => array( 'class' => 'application.commands.SMigrationCommand', ) ), ...
Always put normal migration scripts in ~protected/migrations folder and module migrations in ~protected/modules/nameofmodule/migrations.
now open CMD/terminal CD to ~protected. invoke command yiic migrate [up|down] [...] for normal migrations AND yiic migrate module <module_name> [up|down] [...] for module migrations
Only migrate create,migrate up and migrate down is working currently. Will upgrade gradually.