I have a dev Ruby on Rails database full of data. I want to delete everything and rebuild the database. I\'m thinking of using something like:
rake db:recrea
Because in development , you will always want to recreate the database,you can define a rake task in your lib/tasks folder like that.
namespace :db do task :all => [:environment, :drop, :create, :migrate] do end end
and in terminal you will run
rake db:all
it will rebuild your database