class Byebug::Runner

def prepare_options

def prepare_options
  OptionParser.new(banner, 25) do |opts|
    opts.banner = banner
    opts.on '-d', '--debug', 'Set $DEBUG=true' do
      $DEBUG = true
    end
    opts.on('-I', '--include list', 'Add to paths to $LOAD_PATH') do |list|
      $LOAD_PATH.push(list.split(':')).flatten!
    end
    opts.on '-m', '--[no-]post-mortem', 'Use post-mortem mode' do |v|
      Setting[:post_mortem] = v
    end
    opts.on '-q', '--[no-]quit', 'Quit when script finishes' do |v|
      @quit = v
    end
    opts.on '-x', '--[no-]rc', 'Run byebug initialization file' do |v|
      Byebug.run_init_script if v
    end
    opts.on '-s', '--[no-]stop', 'Stop when script is loaded' do |v|
      @stop = v
    end
    opts.on '-r', '--require file', 'Require library before script' do |lib|
      require lib
    end
    opts.on '-R', '--remote [host:]port', 'Remote debug [host:]port' do |p|
      self.remote = Byebug.parse_host_and_port(p)
    end
    opts.on '-t', '--[no-]trace', 'Turn on line tracing' do |v|
      Setting[:linetrace] = v
    end
    opts.on '-v', '--version', 'Print program version' do
      self.version = VERSION
    end
    opts.on('-h', '--help', 'Display this message') do
      self.help = opts.help
    end
  end
end