module Thor::Actions

def run(command, config = {})


end
run('ln -s ~/edge rails')
inside('vendor') do

==== Example

to append an executable to command execution.
config:: give :verbose => false to not log the status, :capture => true to hide to output. Specify :with
command:: the command to be executed.
==== Parameters

Executes a command returning the contents of the command.
def run(command, config = {})
  return unless behavior == :invoke
  destination = relative_to_original_destination_root(destination_root, false)
  desc = "#{command} from #{destination.inspect}"
  if config[:with]
    desc = "#{File.basename(config[:with].to_s)} #{desc}"
    command = "#{config[:with]} #{command}"
  end
  say_status :run, desc, config.fetch(:verbose, true)
  return if options[:pretend]
  env_splat = [config[:env]] if config[:env]
  if config[:capture]
    require "open3"
    result, status = Open3.capture2e(*env_splat, command.to_s)
    success = status.success?
  else
    result = system(*env_splat, command.to_s)
    success = result
  end
  abort if !success && config.fetch(:abort_on_failure, self.class.exit_on_failure?)
  result
end