Is there a way that allows me to combine lists vertically?
For example, if I have these two lists:
AE BF CG DH
I would like to get the following:
A E B F C G D H
It's simple, just place the cursor on the column between the lists. Insert visualblock-mode <Cv> , check the entire column, press r to replace it, then <CR> and you have what you want.
<Cv>
r
<CR>
:%s/\v^(\w) /\1\r/g : ........... command % ........... whole file \v .......... very magic (avoid backslashes) (\w) ........ word character \1 .......... all patter in parenthesis \r .......... Carriage Return "Enter" g ........... globally
You can also do this with an external filter. Mark the corresponding lines in visual mode and press ! . The following filter does what you want on a POSIX system:
paste -sd' ' | tr ' ' '\n'