因此,下面是我的VIM文件的copypasta。它的7000多行很长,所以我试图找到清理它的命令。基本上,我需要换行才能从P:或F:开始,但要这样做,我必须将任何错误地换行的行移回正确的行:下面,以“Nobody can ......”开头的行开头被搬回来......
P: Well at this stage here, I can.t really say for anything really, cause I don.t know anything. $
F: Okay. And that.s my job Rob, my job is to come in here and explain $
some stuff to you and then once you.ve a better understanding you can choose whether or not you want to explain that stuff. Alright, because that.s gonna be your choice I.m not gonna force you to say anything. I.m not gonna make you do anything you don.t want to do. $
Nobody can ever make you do that, nobody can make Robert $
答案 0 :(得分:2)
使用:v
查找所有不以P
或F
开头的行,并将其加入前一行:
:v/^\(P\|F\)/ normal kJ