Class: Dash::Cli::Alias::Command

Inherits:
Thor::DynamicCommand
  • Object
show all
Defined in:
lib/dash/cli/alias/command.rb

Instance Method Summary collapse

Instance Method Details

#run(instance, args = []) ⇒ Object



2
3
4
5
6
7
8
9
# File 'lib/dash/cli/alias/command.rb', line 2

def run(instance, args = [])
  if (command = DASH.resolve_alias(name))
    DASH.reset
    Dash::Cli::Main.start(Shellwords.split(command) + ARGV[1..-1])
  else
    super
  end
end