require 'optparse' $options = {} OptionParser.new do |opts|         opts.on("-r")                       { |s| $options[:r] = true } 	opts.on("-i", '-i INPUT', "input ") { |s| $options[:i] = s }  	opts.on("-o", '-o OUTPUT',"output") { |s| $options[:o] = s }  	opts.on("-m", '-m MODEL', "model ") { |s| $options[:m] = s }  	opts.on("-d", '-d NTCIR', "ntcir ") { |s| $options[:d] = s }  end.parse! $dir_queryfile = File.dirname($options[:i])  puts $options . . . 
  |