Skip to main content


Today, I discovered that in #Rails 8, the command for setting up a fresh database has changed from `db:migrate` to `db:prepare`. This caught me off guard since it wasn’t mentioned in the [Rails 8.0 release notes](guides.rubyonrails.org/v8.0/8_…).

Thankfully, I found it documented in the [ActiveRecord CHANGELOG](github.com/rails/rails/blob/8-…).

However, testing migrations now requires `rails db:migrate:reset`, which feels far from intuitive.

#ruby

in reply to miry

For a fresh database, it used to be db:setup, or db:schema:load.

Lo, thar be cookies on this site to keep track of your login. By clicking 'okay', you are CONSENTING to this.