Skip to content

sg: Add `sg migration revert <commit>`

Administrator requested to merge ef/sg-migration-revert into main

Created by: efritz

Add a command to revert all of the migrations defined in a commit that was since reverted from main. This command:

  • identifies the set of migrations new to that commit
  • replaces their "up" query with a no-op, but leaves their down query alone
  • adds a new migration that runs the "down" queries of each migration to ensure that any environments that ran this will have it undone

Merge request reports

Loading