I have this file
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
~
~
I want to enter a description(copy and paste)
in a block after dvb-apps:
so result like this
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps:
dvb-apps: Bla bla,description bla bla bla
dvb-apps: Bla bla,description bla bla bla
dvb-apps: Bla bla,description bla bla bla
dvb-apps: Bla bla,description bla bla bla
dvb-apps:
dvb-apps:
If i use the standard paste from console i obtain
dvb-apps: Bla bla,description bla bla bla
Bla bla,description bla bla bla
Bla bla,description bla bla bla
Bla bla,description bla bla bla
dvb-apps:
dvb-apps:
dvb-apps:
How to paste into a block?
Best Answer
Copy the content to your document in vim as you do, presumably with the middle mouse button in X, using insert mode, but on separate lines.
Then go to the first column of the first of the newly inserted lines and go into visual block mode
CTRL+v
where you can select the content. The only issue here could be different line lengths that sometimes make it hard to select the whole content in visual block. You might have to add some whitespace to the last line first in order to be able to select all columns of all lines.After having done so, press
d
for delete, navigate to the correct column of the first target line and paste withp
.Alternatively, doing the task but not an actual solution to your question, asking to do it in vim, would be to create two separate files:
and
and then use
to put both files together.