From 727342a767f4b89d322b9a1439e77d872d01839e Mon Sep 17 00:00:00 2001 From: mhchia Date: Sun, 4 Aug 2019 00:11:49 +0800 Subject: [PATCH] Move flake8 settings to tox.ini And add flake8 in the Makefile. --- .flake8 | 6 ------ Makefile | 1 + tox.ini | 8 +++++--- 3 files changed, 6 insertions(+), 9 deletions(-) delete mode 100644 .flake8 diff --git a/.flake8 b/.flake8 deleted file mode 100644 index 15e152a1..00000000 --- a/.flake8 +++ /dev/null @@ -1,6 +0,0 @@ -[flake8] -ignore = E203, E266, E501, W503 -max-line-length = 80 -max-complexity = 18 -select = B,C,E,F,W,T4,B9 - diff --git a/Makefile b/Makefile index 0edddd0d..2cc4959f 100644 --- a/Makefile +++ b/Makefile @@ -10,6 +10,7 @@ lintroll: # TODO: add flake8 black --check $(FILES_TO_LINT) isort --recursive --check-only $(FILES_TO_LINT) + flake8 $(FILES_TO_LINT) protobufs: cd libp2p/pubsub/pb && protoc --python_out=. rpc.proto diff --git a/tox.ini b/tox.ini index cb55dd56..57edafcd 100644 --- a/tox.ini +++ b/tox.ini @@ -6,9 +6,11 @@ envlist = lint [flake8] -max-line-length= 100 -exclude=*_pb2*.py -ignore= +max-line-length = 100 +exclude = *_pb2*.py +ignore = E203, E266, E501, W503 +max-complexity = 18 +select = B,C,E,F,W,T4,B9 [isort] force_sort_within_sections=True