diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index cb8b8c36..cf12c605 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -37,6 +37,8 @@ jobs: run: isort --profile black --length-sort --line-width 120 -c . - name: Lint with black run: black -l 120 --check . + - name: Lint with pycodestyle + run: pycodestyle --show-source capa/ scripts/ tests/ - name: Check types with mypy run: mypy --config-file .github/mypy/mypy.ini capa/ scripts/ tests/ diff --git a/setup.cfg b/setup.cfg new file mode 100644 index 00000000..5e0292f4 --- /dev/null +++ b/setup.cfg @@ -0,0 +1,21 @@ +[bdist_wheel] +universal = 1 + +[aliases] +test = pytest + +[pycodestyle] +# the following suppress lints that conflict with the project's style: +# +# E203 Whitespace before : +# E302 expected 2 blank lines, found 1 +# E402 module level import not at top of file +# E501 line too long (209 > 180 characters) +# E712 comparison to False should be 'if cond is False:' or 'if not cond:' +# E722 do not use bare 'except' +# E731 do not assign a lambda expression, use a def +# W291 trailing whitespace +# W503 line break before binary operator +ignore = E203, E302, E402, E501, E712, E722, E731, W291, W503 +max-line-length = 180 +statistics = True