Class: Space::Architect::CLI::Architect::Worktree::Remove

Inherits:
BaseCommand
  • Object
show all
Defined in:
lib/space_architect/cli/architect.rb

Instance Method Summary collapse

Methods inherited from BaseCommand

commit_message_options, phase

Instance Method Details

#call(iteration:, lane:, **opts) ⇒ Object



676
677
678
679
680
681
682
683
684
685
686
# File 'lib/space_architect/cli/architect.rb', line 676

def call(iteration:, lane:, **opts)
  setup_terminal(**opts.slice(:color, :colors))
  handle_errors do
    render(store.find) do |sp|
      project = ArchitectProject.new(space: sp)
      project.worktree_remove(iteration, lane)
      terminal.say "Removed worktree for #{iteration}/#{lane}"
      CLI.record_outcome(Outcome.new(exit_code: 0))
    end
  end
end