我使用Pathogen安装了Syntastic,并尝试了所有我能想到的方法来让Syntastic识别我的pylint检查器。
pylint检查器已经安装在这里。
/home/myself/.local/bin/pylint
我复制了我的路径并
/home/myself/.local/bin
确实在$PATH变量中。
我的.vimrc文件如下:
set tabstop=4
execute pathogen#infect()
syntax on
filetype plugin indent on
let g:syntastic_mode_map = { 'mode': 'passive',
\ 'active_filetypes': ['python'],
\ 'passive_filetypes': ['perl'] }
let g:syntastic_python_checkers = ['pylint', 'python']
然而,当我运行该命令时
SyntasticInfo
在vim中,我依然看到
Syntastic: passive mode enabled
Syntastic version: 3.4.0-79
Info for filetype:
Available checker(s):
Currently enabled checker(s):
我花了很长时间在谷歌上搜索这个问题,有人知道我忘了什么吗?
编辑/答案: 如果还有人需要类似的帮助,可以尝试这个方法:
:setfiletype python
似乎做得不错。