Add rake task to load sdg
This task should be useful for existing installations that are going to upgrade the app and want to load SDG data into an already existing database.
This commit is contained in:
committed by
Javi Martín
parent
cbe84450ac
commit
c7c8309ad1
@@ -4,4 +4,10 @@ namespace :db do
|
||||
@avoid_log = args[:print_log] == "avoid_log"
|
||||
load(Rails.root.join("db", "dev_seeds.rb"))
|
||||
end
|
||||
|
||||
desc "Load SDG content into database"
|
||||
task load_sdg: :environment do
|
||||
ApplicationLogger.new.info "Adding Sustainable Development Goals content"
|
||||
load(Rails.root.join("db", "sdg.rb"))
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user