From: Brian Candler Date: 2011-07-29T05:38:57+09:00 Subject: Re: OptionParser on option separator "--" It's standard option parsing behaviour. -- indicates "end of options", and is important if any of the subsequent parameters otherwise looks like an option. require "optparse" opts = OptionParser.new p opts.parse(%w{hello -- world --flurble --boing}) # => ["hello", "world", "--flurble", "--boing"] p opts.parse(%w{hello world --flurble --boing}) # invalid option: flurble Also, quoting from the getopt(1) manpage: "Each parameter not starting with a `-', and not a required argument of a previous option, is a non-option parameter. Each parameter after a `--' parameter is always interpreted as a non-option parameter. -- Posted via http://www.ruby-forum.com/.