Code Yarns ‍👨‍💻
Tech BlogPersonal Blog

How to split line in Vim

📅 2014-Aug-25 ⬩ ✍️ Ashwin Nanjappa ⬩ 📚 Archive

To split a line at the cursor position you can use the usual sequence of i, Enter and Esc. This enters insert mode, adds a new line and then escapes from insert mode.

If your cursor is at a space in English text then you are in luck. You can insert a newline here by replacing the space with a newline character. To do that in Vim, press r and Enter. No need to escape insert mode!

Tried with: Vim 7.4