Skip to content
Snippets Groups Projects
Commit ae81ecc2 authored by Mateus Rambo Strey's avatar Mateus Rambo Strey
Browse files

improve setup

parent 4b0e83cf
No related branches found
No related tags found
No related merge requests found
namespace :portalmec do
desc 'setup initial environment'
task :setup do
# runs db:drop db:create db:migrate
Rake::Task['db:migrate:reset'].invoke
Rake::Task['db:seed'].invoke
......@@ -10,14 +8,9 @@ namespace :portalmec do
Rake::Task['import:learning_objects'].invoke
Rake::Task['import:topics'].invoke
Rake::Task['topics:define_defaults'].invoke
Rake::Task['object_type:restart'].invoke
puts "\n Want to identify unknown mime types in learning objects' attachments? [Y/N]"
answer = STDIN.gets.chomp
Rake::Task['attachments:set_unknown'].invoke if answer =~ /y/i
puts "\n Want to generate thumnails? [Y/N]"
answer = STDIN.gets.chomp
Rake::Task['thumbnail:create_missing'].invoke if answer =~ /y/i
Rake::Task['attachments:set_unknown'].invoke
Rake::Task['thumbnail:create_missing'].invoke
end
end
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment