Use cmd rather than func for migration operations