如何在Spyder IDE中为Pylint设置配置文件



如何在Spyder IDE中为Pylint(命令行开关--rcfile)指定自定义配置文件?

我尝试编辑pylint.bat并像这样pylint-gui.bat

python "%~dpn0" %* --rcfile="P:/path/to/pylintrc"

但没有成功。我总是在输出中看到:

未找到配置文件,使用默认配置

Spyder将运行pylint.exe,而不是pylint.bat,这就是为什么你尝试的不起作用。

最简单的方法是将 pylintrc 放在您的项目文件夹中,因为 pylint 会自动查看那里。

https://docs.pylint.org/run.html#command-line-options

编辑:上面的链接似乎已经死了。看这里: https://pylint.readthedocs.io/en/latest/user_guide/run.html#command-line-options

最新更新