You are not logged in.
Pages: 1
I have a text file that is a busload of URLs, all strung together in one continuous block and separated only by a comma. How can I quickly turn the commas into line breaks?
I’ve tried TextMate but don’t seem to be able to do it. I’ve tried importing into a spreadsheet but the commas are treaded like column separators when what I’m really after is a single column of URLs (each to it’s own row).
I suspect command-line is the answer, but I’m many years removed from emacs, etc.
Suggestions?
Offline
Guessing that TextMate has a find and replace that can do , -> \r (assuming \r is indeed the right line break on a mac.)
— Steve
Textile | My plugins on GitHub | @netcarver
Offline
Replacing , with \n works for me.
<txp:Els /> ;)
Tag Reference | Unexpected behaviour? Check the tag trace | Still no clue? Check the names of your custom fields
Offline
Strange, not working for me. Steve’s example just replaces the comma with \r. And Els’ example inserts the \n after the comma, even though it’s a find/replace. Still using TextMate, btw.
Offline
I don’t know TextMate, but what also works in a text editor is to copy a line break and paste it into the ‘replace with’ field.
<txp:Els /> ;)
Tag Reference | Unexpected behaviour? Check the tag trace | Still no clue? Check the names of your custom fields
Offline
Offline
Pages: 1