Created
November 19, 2013 04:45
-
-
Save cp/7540466 to your computer and use it in GitHub Desktop.
Simple script for taking a CSV of emails and converting it to something Mail.app likes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'csv' | |
emails = Array.new | |
text = File.read('emails.csv').gsub(/\\"/,'""') | |
CSV.parse(text, headers: true, header_converters: :symbol) do |row| | |
emails << row[:email] | |
end | |
puts emails.join(',') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment