discourse/migrations/lib/importer.rb
Gerhard Schlager 4141d4e0a6 DEV: Restructure importer files
This is similar to converters: We allow directories to structure files within the importer directory, but try to keep the namespace the same.

Currently the restructured namespaces look like this:

* `Migrations::Converters::Discourse`
  * migrations/lib/converters/discourse/steps
  * migrations/lib/converters/discourse/utilities

* `Migrations::Importer`
  * migrations/lib/importer/name_finder

* `Migrations::Importer::Steps`
  * migrations/lib/importer/steps/badges
  * migrations/lib/importer/steps/categories
  * migrations/lib/importer/steps/groups
  * migrations/lib/importer/steps/settings
  * migrations/lib/importer/steps/tags
  * migrations/lib/importer/steps/topics
  * migrations/lib/importer/steps/users
2025-11-03 11:23:53 +01:00

16 lines
356 B
Ruby
Vendored

# frozen_string_literal: true
module Migrations
module Importer
module Steps
end
def self.execute(options)
config_path = File.join(::Migrations.root_path, "config", "importer.yml")
config = YAML.load_file(config_path, symbolize_names: true)
executor = Executor.new(config, options)
executor.start
end
end
end