Friday, January 31, 2014

Rails Destroy Table, Create Table, Migrate

Ever messed up your db by not using the rails destroy migration?

Instead of running the rake commands separately like so:

rake db:drop 
rake db:create
rake db:migrate

... you can stack them into one command.

rake db:drop db:create db:migrate

This way you don't have to wait for the environment to reload for each rake command.

No comments:

Post a Comment