How do I create a pylintrc file

人盡茶涼 提交于 2019-11-27 11:37:24

You may put it in:

  • /etc/pylintrc for default global configuration
  • ~/.pylintrc for default user configuration
  • <your project>/pylintrc for default project configuration (used when you'll run pylint <your project>)
  • wherever you want, then use pylint --rcfile=<wherever I want>

Also notice when generating the rc file, you may add option on the command line before the --generate-rcfile, they will be considered in the generated file.

According to documentation here, we can use the following command to generate a pylint rc file with all its options present:

pylint --generate-rcfile > ~/.pylintrc

The above command will create the file .pylintrc under your home directory. Then you can tweak the rc file to fit your needs.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!