Hi I have the following CSV input data which features several newline and carriage return characters. I am trying to cleanup the file with SED:
"Data1","This<LF>
Is<LF>
Foobar"<CR><LF>
"Data2","Additional<LF>
Data<CR><LF>
With Inline CR LF<CR><LF>
End of Data."<CR><LF>
Note: CR and LF equals actual \r and \n here
I want to replace all linefeeds which have no prepended " - the double quoted character is imported here to consider. I manage to filter out all linefeeds but do not know how to tell SED to ignore those with a specific pattern.
Output is expected to look like this:
"Data1","This Is Foobar"
"Data2","Additional Data With Inline CR LF End of Data."
Any ideas?