重播vim宏,直到缓冲区结束 [英] replay a vim macro until end of buffer
本文介绍了重播vim宏,直到缓冲区结束的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想在vim中运行一个刚在寄存器"x
"中记录的宏,该宏在打开的缓冲区的每一行中,从我的光标到缓冲区的结尾.我该怎么办?
I want to run a macro I just recorded in register "x
" on every single line of an open buffer, from my cursor to end of the buffer, in vim. How do I do that?
我知道我可以重播该宏n次:
I know I can replay the macro n times:
15@x
...或者只是按住@
直到我到达最后一行,但我只想敲击几下并完成操作.
...or just hold down @
until I reach the the last line, but I want to just hit a few keystrokes and be done with it.
提前谢谢.
推荐答案
我个人会这样做
VG:normal @x
将寄存器更改为您指定的寄存器.
changed register to the one you specified.
这篇关于重播vim宏,直到缓冲区结束的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文