Class: Textus::CLI::Verb::Migrate
- Inherits:
-
Textus::CLI::Verb
- Object
- Textus::CLI::Verb
- Textus::CLI::Verb::Migrate
- Defined in:
- lib/textus/cli/verb/migrate.rb
Instance Attribute Summary
Attributes inherited from Textus::CLI::Verb
Instance Method Summary collapse
Methods inherited from Textus::CLI::Verb
command_name, #context_for, descendants, #emit, inherited, #initialize, needs_store?, option, options, parent_group, #parse, #resolved_role, #session_for
Constructor Details
This class inherits a constructor from Textus::CLI::Verb
Instance Method Details
#call(store) ⇒ Object
10 11 12 13 14 |
# File 'lib/textus/cli/verb/migrate.rb', line 10 def call(store) path = positional.shift or raise UsageError.new("migrate requires <plan.yaml>") plan_yaml = File.read(path) emit(session_for(store).migrate(plan_yaml: plan_yaml, dry_run: dry_run || false).to_h) end |