adding pylint settings file

This commit is contained in:
Roman Mogilatov 2015-03-11 15:39:28 +02:00
parent dbde2b157e
commit dbde0ff579
2 changed files with 51 additions and 2 deletions

49
.pylintrc Normal file
View File

@ -0,0 +1,49 @@
[MASTER]
# Add <file or directory> to the black list. It should be a base name, not a
# path. You may set this option multiple times.
ignore=utils,test
[MESSAGES CONTROL]
# Disable the message(s) with the given id(s).
# disable-msg=
[SIMILARITIES]
# Minimum lines number of a similarity.
min-similarity-lines=5
[TYPECHECK]
ignore-mixin-members=yes
# ignored-classes=
zope=no
# generated-members=providedBy,implementedBy,rawDataReceived
[DESIGN]
# Maximum number of arguments for function / method
max-args=10
# Maximum number of locals for function / method body
max-locals=20
# Maximum number of return / yield for function / method body
max-returns=10
# Maximum number of branch for function / method body
max-branchs=10
# Maximum number of statements in function / method body
max-statements=60
# Maximum number of parents for a class (see R0901).
max-parents=10
# Maximum number of attributes for a class (see R0902).
max-attributes=30
# Minimum number of public methods for a class (see R0903).
min-public-methods=0
# Maximum number of public methods for a class (see R0904).
max-public-methods=30

View File

@ -26,11 +26,11 @@ def tag():
@manager.command @manager.command
def check(): def check():
"""Check `objects` library and examples with code analyzers.""" """Check `objects` library and examples with code analyzers."""
os.system('pylint objects/') os.system('pylint objects/ --rcfile=./.pylintrc')
os.system('flake8 objects/') os.system('flake8 objects/')
os.system('pep257 objects/') os.system('pep257 objects/')
os.system('pylint examples/') os.system('pylint examples/ --rcfile=./.pylintrc')
os.system('flake8 examples/') os.system('flake8 examples/')
os.system('pep257 examples/') os.system('pep257 examples/')