vjjj " select the block (or whatever works for your actual use case)
:norm yss<p><CR> " execute the normal mode yss command provided by Surround
" on each line of the selection
" note that Vim automatically inserts the range corresponding
" to your visual selection: :'<,'>norm ...
2条答案
按热度按时间uurity8g1#
使用Surround:
或者,如果您对范围有信心:
无插件:
或者一个变体:
如果您对范围有信心,则可以使用上述变量的变体:
或者上述三种变体的单步变体:
或者一个完全不同的方法,使用一个超级简单的替代:
参考:
ewm0tg9j2#
您可以在Hello World上使用多选命令
然后用