I got a file that was created on a mac so it has \r (CR) on each line, and two CRs after all the data ends. To be more clear, each column to be in the csv is seperated by the CR and each row is seperated by two CRs. Right now i am using tr w/o success. tr '\r' ',' < input > ouput. but that will still et comma at end and i cant handle the two carriage returns.
this is sample data:
name John Smith
company Foobar Enterprises
address1 123 Main St.
city New York
notes I like to know more about the product
i guess a small bash script would be fruitful but i am awful at regexp :-(
thanks so much!