NERD评论者:如何注释掉一个范围 [英] NERD commenter : How to comment out a range

查看:20
本文介绍了NERD评论者:如何注释掉一个范围的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 NERD 评论者

假设我想注释掉 78 到 172 行.这就是我所做的.我计算差异.那是 94.把我的光标放在第 78 行然后我做: 94 , c space

Let's say that I want to comment out lines from 78 to 172. This is what I do. I calculate the difference. That is 94. put my cursor on line 78 and then I do: 94 , c space

这样我就从第 78 行开始注释了 94 行.

In this way I comment 94 lines starting from line number 78.

我不喜欢我需要做的计算.我希望通过一个类似

I don't like the calculation that I need to do. I was hoping to pass a range something like

78,172 注释第 78 行到第 172 行的代码.我是否遗漏了什么.

78,172 to comment the code from line 78 to 172. Am I missing something.

看这个插件的火爆程度,好像一定有​​更好的评论和取消评论的方式.

Looking at the popularity of this plugin, it seems there must be a better way to comment and uncomment.

推荐答案

我会(在可视模式下):78v172G 选择并突出显示第 78 到 172 行,然后只需 ,c<空格>.

I'd do (in visual mode) :78v172G to select and highlight lines 78 to 172, then just ,c<space>.

这篇关于NERD评论者:如何注释掉一个范围的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆