如何使用NERD Comment取消注释/评论python文件

时间:2017-11-25 09:26:54

标签: python vim nerdcommenter

官方文档中给出的示例是C. 然后我改成了python

" Add spaces after comment delimiters by default
let g:NERDSpaceDelims = 1

" Use compact syntax for prettified multi-line comments
let g:NERDCompactSexyComs = 1

" Align line-wise comment delimiters flush left instead of following code indentation
let g:NERDDefaultAlign = 'left'

" Add your own custom formats or override the defaults
let g:NERDCustomDelimiters = { 'python': { 'left': '#' } } <==

" Allow commenting and inverting empty lines (useful when commenting a region)
let g:NERDCommentEmptyLines = 1

" Enable trimming of trailing whitespace when uncommenting
let g:NERDTrimTrailingWhitespace = 1

"

但是当我点击<leader>cc并且点击<leader>cu时无法正常工作时它无法正常工作?

此外,如何更改此插件的默认映射键,例如将<leader>cc更改为<leader>c以进行评论?

0 个答案:

没有答案