Skip to content

Instantly share code, notes, and snippets.

@skamithi
Last active December 23, 2015 23:19
Show Gist options
  • Save skamithi/6708737 to your computer and use it in GitHub Desktop.
Save skamithi/6708737 to your computer and use it in GitHub Desktop.
rake test to clean out test and dev db. Then regenerate both dbs.
namespace :db do
desc 'regenerate test and dev db'
task :regenerate do
Rake::Task['db:drop'].invoke
Rake::Task['db:create'].invoke
Rake::Task['db:migrate'].invoke
Rake::Task['db:test:purge'].invoke
Rake::Task['db:test:prepare'].invoke
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment