下载地址:http://www.vim.org/scripts/script.php?script_id=1528
created by
Jasmeet Singh Anand
script type
utility
description
Global Plugin to comment and un-comment lines in different source files in both normal and visual <Shift-V> mode
usage:
ctrl-c to comment a single line
ctrl-x to un-comment a single line
shift-v and select multiple lines, then ctrl-c to comment the selected multiple lines
shift-v and select multiple lines, then ctrl-x to un-comment the selected multiple lines
supports: c, c++, java, php[2345], proc, css, html, htm, xml, xhtml, vim, vimrc, sql, sh, ksh, csh, perl, tex, fortran, ml, caml, ocaml, vhdl, haskel and normal files
install details
For VIM 6 and higher -
Stick this file in your ~/.vim/plugin directory or in some other 'plugin' directory that is in your runtime path
For VIM 5 -
Stick this file somewhere and 'source <path>/comments.vim' it from your ~/.vimrc file