Vim:让 gq 不取代 `**'在评论区
假设我有一个很好的注释块,例如下面的注释块
/*
** This is a nice comment block. Displace the `**'s and I will eat your nose! Also, here is a long line of text clearly longer than the textwidth, which should force gq to rearrange the lines. Wheeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee...
**
**
*/
,并且我应用 gq 来格式化它并确保没有行超过字符数。如何让 gq
不替换每个注释行前面的初始“**”?
非常感谢!
Suppose I have a nice comment block, such as the one below
/*
** This is a nice comment block. Displace the `**'s and I will eat your nose! Also, here is a long line of text clearly longer than the textwidth, which should force gq to rearrange the lines. Wheeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee...
**
**
*/
and that I apply gq
to format it and ensure that no line exceeds the character count. How can I get gq
not to displace the initial `**'s that prepend each comment line?
Thank you very much!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
请参阅
:帮助格式注释
。我得到你想要的结果See
:help format-comments
. I get the result you want from