5
votes
2answers
153 views

Carriage return vs newline in vim

In vim, when I opened a file, I wanted to add two empty lines at the end of each current line. I used the following switch: %s/$/\n\n/ Apparently, this does not work, but what does work is: ...
0
votes
3answers
153 views

Make VIM act as Notepad++ on mixed line endings

I've googled all around and found tons of weird solutions to ^M problem, but couldn't find one and simple: how could I just open any file, like in Notepad++ and work on it? I don't want to mess with ...
2
votes
1answer
150 views

Insert newlines with vim

How to insert newlines in vim? For example in a file containing test-classes; classes; xmlunit-1.3.jar I am looking for the vim equivalent of sed command sed -i 's/; /\n/g' classpath to obtain ...