Skip to content

Commit

Permalink
Update README.rst
Browse files Browse the repository at this point in the history
add reqiure
  • Loading branch information
510908220 committed Jun 16, 2017
1 parent 9b6df2c commit f67e0f1
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,22 @@ jenkins pylint api.
* Free software: MIT license
* Documentation: https://lintjenkins.readthedocs.io.

Require
--------

1. **目标机器装有jenkins+violations**

2. **被检查的python代码所在目录符合包的形式,如**:

- `__init__.py`
- `requirements.txt`
- `pylint.cfg`

3. **pylint配置文件也需要修改**.

- 没有配置可以使用`pylint --generate-rcfile > pylint.cfg`生成配置.
- 将`output-format`项的值改为`parseable`
- `init-hook`添加`'import sys; sys.path.append("/var/lib/jenkins/workspace/xxx")'`,`xxx`为jenkins job名. 否则会出现`W0403 Relative import 'xxxx'警告`

Example
--------
Expand Down

0 comments on commit f67e0f1

Please sign in to comment.