/array-to-csv

A gem including a simple method to convert arrays to CSV output.

Primary LanguageRubyOtherNOASSERTION

Adds Array#to_csv method that converts the contents of the array to CSV format.

Examples:

    [['a', 'b'], ['c', 'd']].to_csv
    #=> "a","b"\n"c","d"
    ['Report on somesuch', 
      ['name', 'value'],
      ['foo', 156],
      ['bar', 24]].to_csv
    #=> "Report on somesuch"\n"name","value"\n"foo","156"\n"bar","24"

This gem is released under a broad open-source license. See LICENSE for more details.