Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/vim/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
.vimrc中的django html语法配置_Vim_Vim Plugin_Syntastic - Fatal编程技术网

.vimrc中的django html语法配置

.vimrc中的django html语法配置,vim,vim-plugin,syntastic,Vim,Vim Plugin,Syntastic,我是vim新手,我刚刚安装了syntastic,我的问题是如何激活syntastic来检查htmldjango类型,我安装了pylint和pylint django,这是我的SyntasticInfo Syntastic version: 3.8.0-3 (Vim 800, Linux, GUI) Info for filetype: htmldjango Global mode: active Filetype htmldjango is active The current file wil

我是vim新手,我刚刚安装了syntastic,我的问题是如何激活syntastic来检查htmldjango类型,我安装了pylint和pylint django,这是我的SyntasticInfo

Syntastic version: 3.8.0-3 (Vim 800, Linux, GUI)
Info for filetype: htmldjango
Global mode: active
Filetype htmldjango is active
The current file will be checked automatically
Available checkers: -
Currently enabled checkers: -

谢谢

这不起作用有两个原因。首先,要让pylint django“尝试”检查htmldjango文件,必须将其插入到.vimrc文件中:

let g:syntastic_python_pylint_args = "--load-plugins pylint_django"
let g:syntastic_htmldjango_checkers = ['python/pylint']
请注意,您必须指定
'python/pylint'
作为检查器,因为这是htmldjango文件类型的外来检查器

这将解决您的
SyntasticInfo
问题:

Currently enabled checker: python/pylint

然而,目前python pylint根本不支持djangohtml模板,因此即使您完成了这项工作,您也会感到失望,并会出现各种语法错误…因为检查器只支持django模型和视图文件类型…(-)\ლ)

这不起作用有两个原因。首先,要让pylint django“尝试”检查htmldjango文件,必须将其插入.vimrc文件中:

let g:syntastic_python_pylint_args = "--load-plugins pylint_django"
let g:syntastic_htmldjango_checkers = ['python/pylint']
请注意,您必须指定
'python/pylint'
作为检查器,因为这是htmldjango文件类型的外来检查器

这将解决您的
SyntasticInfo
问题:

Currently enabled checker: python/pylint

然而,目前python pylint根本不支持djangohtml模板,因此即使您完成了这项工作,您也会感到失望,并会出现各种语法错误…因为检查器只支持django模型和视图文件类型…(-)\ლ)

> StutTAST对于<代码> HTMLDJango 没有任何有用的检查程序。无论如何,您应该考虑阅读手册。SytTASTIC对于<代码> HTMLDJango 没有任何有用的检查器。无论如何,您应该考虑阅读手册。