Jürgen Krämer wrote:
Hi,
Fabio Rotondo schrieb:
I have a text file with many lines made like this:
[EMAIL PROTECTED]@[EMAIL PROTECTED]@
And I'd like to have them splitted on "@" in newlines.
I have tried:
:%s/@/\n/g
but it does not work.
What am I missing?
\n in the second part of a substitution denotes the NUL character which
is used internally to represent end-of-line. To insert newlines you
have to use \r:
:%s/@/\r/g
Regards,
Jürgen
Side-question: What line endings does \r insert? Or is this dependant on
fileformat?
Wim