lib/genesis/tasks/genesis.rake in genesis-1.5.0 vs lib/genesis/tasks/genesis.rake in genesis-1.6.0
- old
+ new
@@ -25,28 +25,11 @@
desc "Recreates the databse by migrating down to VERSION=0 and then db:migrate and db:seed"
task :mulligan => :environment do
raise 'Cannot seed production' if ENV['RAILS_ENV'] == 'production' || Rails.env.production?
- ENV['VERSION']= '0'
- Rake::Task['db:migrate'].invoke
- Rake::Task['db:migrate'].reenable
- ENV.delete 'VERSION'
- Rake::Task["db:migrate"].invoke
Genesis::SchemaSeed.delete_all
- Rake::Task['db:genesis'].invoke
- end
-
- namespace :mulligan do
-
- desc 'Recreates database using db:migrate:reset and db:seed (helpful when an irreversible migration is blocking db:mulligan)'
- task :reset => :environment do
- raise 'Cannot seed production' if ENV['RAILS_ENV'] == 'production' || Rails.env.production?
-
- Rake::Task['db:migrate:reset'].invoke
- Rake::Task['db:genesis'].invoke
- end
-
+ Rake::Task['db:reset'].invoke
end
desc "An alias for the db:genesis task"
task :seed => :environment do
Rake::Task['db:genesis'].invoke