Class: SpaceArchitect::CLI::Path

Inherits:
Dry::CLI::Command
  • Object
show all
Includes:
GlobalOptions, Helpers
Defined in:
lib/space_architect/cli/path.rb

Instance Method Summary collapse

Methods included from Helpers

#display_date, #handle_errors, #project_config, #render, #setup_terminal, #state, #store, #terminal

Methods included from GlobalOptions

included

Instance Method Details

#call(identifier: nil, **opts) ⇒ Object



12
13
14
15
16
17
18
# File 'lib/space_architect/cli/path.rb', line 12

def call(identifier: nil, **opts)
  setup_terminal(**opts.slice(:color, :colors))
  render(store.path_for(identifier)) do |path|
    terminal.say terminal.path(path)
    CLI.record_outcome(Outcome.new(exit_code: 0))
  end
end