2019-05-02 17:17:27 -05:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2022-01-05 11:45:08 -06:00
|
|
|
if ARGV.length != 1 || !File.exist?(ARGV[0])
|
2023-01-07 05:53:14 -06:00
|
|
|
STDERR.puts "", "Usage of mbox importer:", "bundle exec ruby mbox.rb <path/to/settings.yml>"
|
|
|
|
STDERR.puts "",
|
|
|
|
"Use the settings file from #{File.expand_path("mbox/settings.yml", File.dirname(__FILE__))} as an example."
|
2017-05-26 15:26:18 -05:00
|
|
|
exit 1
|
|
|
|
end
|
|
|
|
|
|
|
|
module ImportScripts
|
|
|
|
module Mbox
|
2023-01-07 05:53:14 -06:00
|
|
|
require_relative "mbox/importer"
|
2020-03-13 17:59:14 -05:00
|
|
|
Importer.new(ARGV[0]).perform
|
2017-05-26 15:26:18 -05:00
|
|
|
end
|
|
|
|
end
|