lib/runnable/extended.rb in runnable-0.2.3 vs lib/runnable/extended.rb in runnable-0.2.4

- old
+ new

@@ -18,16 +18,12 @@ require 'runnable/command_parser' # Parse the parameter hash using the extended standard. class Extended < CommandParser - # Convert a hash in a Extended style string options. - # @return [String] Extended-style parsed params in a raw character array. + # Convert a hash in an array of 'Extended style' option strings. + # @return [Array] Extended-style parsed params. def parse - options = "" - @params.each do | param , value | - options = "#{options} -#{param} #{value} " - end - options.strip + @params.collect { |param , value| ["-#{param}", "#{value}"] } end end