开发者

How to comment in Vim's config files: ".vimrc"?

How do I add a comment in Vim's configuration files, lik开发者_运维问答e .vimrc?


A double quote to the left of the text you want to comment.

Example: " this is how a comment looks like in ~/.vimrc

To be clear: Do not include a closing double quote. (See comment from Arslan Ali below.)


"This is a comment in vimrc. It does not have a closing quote 

Source: http://vim.wikia.com/wiki/Backing_up_and_commenting_vimrc


Same as above. Use double quote to start the comment and without the closing quote.

Also, you can have command followed by comment in file .vimrc just like below:

set nu  "display line number 


You can add comments in Vim's configuration file by either:

" brief description of the command    

or:

"" commented command

Taken from here

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜