#! /usr/bin/ruby

parser = OptionParser.new do |q|
  q.banner = "Usage: #{$0} [common-options] ls [options]\n"
  q.on('--directory=DIR', 'change directory', String) {|dir|Dir.chdir(dir)}
end
begin
  parser.parse!(ARGV)
rescue OptionParser::ParseError
  STDERR.puts parser
  exit 1
end
$cmd = proc {|*args| system('ls', *args)}


