Remove trailing '{}' from ARGV if present

This gets the acceptance tests passing on JRuby, which has a bug in Open3.capture3.

See https://github.com/jruby/jruby/issues/1290 for details.