aikeru
aikeru

Reputation: 4003

Delete to the beginning of the next line in vim?

Given text like this:

This is line one.
This is line two.

I would like to change it to this:

This is line one. This is line two.

If my cursor is at the end of line one, how is this done with vim, regardless of what line two starts with? Also, are there different ways to do it with/without whitespace?

Upvotes: 1

Views: 117

Answers (1)

Cyrille
Cyrille

Reputation: 25144

Put your cursor anywhere on line 1, then type J.

Upvotes: 9

Related Questions