dawarich/lib/tasks/exports.rake
2025-04-06 16:31:39 +02:00

13 lines
356 B
Ruby

# frozen_string_literal: true
namespace :exports do
desc 'Migrate existing exports from file system to the new file storage'
task migrate_to_new_storage: :environment do
Export.find_each do |export|
export.migrate_to_new_storage
rescue StandardError => e
puts "Error migrating export #{export.id}: #{e.message}"
end
end
end