Class: Heyterminal::Cli::Commands::Run

Inherits:
Heyterminal::CliCommand show all
Defined in:
lib/heyterminal/cli.rb

Instance Method Summary collapse

Methods inherited from Heyterminal::CliCommand

#safe_call

Instance Method Details

#call(command: nil, **options) ⇒ Object



20
21
22
23
24
25
26
# File 'lib/heyterminal/cli.rb', line 20

def call(command: nil, **options)
  safe_call do
    raise Heyterminal::Error, 'command is required' if command.nil?

    puts Heyterminal::Runner.lod_and_run(options.fetch(:config, nil), command)
  end
end