Miscellaneous commands I don’t want to forget

Rollback ActiveRecord migration

Rollback specific ActiveRecord migration without changing any of the ones in-between (substitute the correct version obviously):

rake db:migrate:down VERSION=20100905201547

useful cheat sheet

Find relevant now-deleted ActiveRecord migrations

git grep SEARCH_TERM_HERE $(git log --format=format:%H -- db/migrate) | grep db/migrate | awk -F: '{print $2}' | sort -u