- begin
- leftover_accounts = plugin.get_leftover_accounts(db_accounts)
- rescue StandardError => e
- puts "There was an error retrieving accounts from the filesystem: #{e.to_s}"
- Kernel.exit(ExitCodes::FILESYSTEM_ERROR)
+# Load each of the plugins that we'll need.
+cfg.plugins.each do |plugin_file|
+ require "#{mode_name}/plugins/#{plugin_file}"
+end
+
+# And the runners.
+require "#{mode_name}/#{mode_name}_runner"
+require "#{mode_name}/#{mode_name}_dummy_runner"
+
+def make_header(plugin_name)
+ # The header that we output before the list of domains/users.
+ # Just the path of this script, the current time, and the plugin name.
+ exe = File.basename($PROGRAM_NAME)
+ header = "#{exe}, "
+
+ current_time = Time.now()
+ if current_time.respond_to?(:iso8601)
+ # Somehow this method is missing on some machines.
+ header += current_time.iso8601.to_s
+ else
+ # Fall back to whatever this looks like.
+ header += current_time.to_s