diff options
Diffstat (limited to 'csv-test.rb')
-rw-r--r-- | csv-test.rb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/csv-test.rb b/csv-test.rb new file mode 100644 index 0000000..c0e43c0 --- /dev/null +++ b/csv-test.rb @@ -0,0 +1,12 @@ +#!/usr/bin/env ruby + +require 'csv' + +# get paths +src_path, dst_path = ARGV + +CSV.open(dst_path, 'wb') do |dst| + CSV.foreach(src_path) do |row| + dst << row + %w{foo} * 2 + end +end |