From f1d1ce8f45bc1bf5b0d91dded10e53cba990b385 Mon Sep 17 00:00:00 2001 From: Michael Prokop Date: Thu, 2 Apr 2020 16:45:12 +0200 Subject: [PATCH] codecheck: rely on flake8, isort + black during build time Switch from pyflakes, pylint + pep8 to flake8, isort + black, and include it in the default build target to get checks during build time. Add relevant packages to Build-Depends. Thanks: Florian Apolloner for the feedback --- Makefile | 10 ++++------ debian/control | 5 ++++- setup.cfg | 2 ++ 3 files changed, 10 insertions(+), 7 deletions(-) create mode 100644 setup.cfg diff --git a/Makefile b/Makefile index b8f1e05..f2103fa 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -all: doc +all: codecheck doc doc: doc_man doc_html @@ -50,11 +50,9 @@ clean: rm -rf html-stamp man-stamp grml2usb.tar.gz grml2usb.tgz grml2usb.tgz.md5.asc codecheck: - pyflakes grml2usb - pylint --include-ids=y --max-line-length=120 grml2usb - # pylint --include-ids=y --disable-msg-cat=C0301 --disable-msg-cat=W0511 grml2usb - # pylint --reports=n --include-ids=y --disable-msg-cat=C0301 grml2usb - pep8 --repeat --ignore E125,E126,E127,E128,E501 grml2usb + flake8 grml2usb + isort --check-only grml2usb + black --check grml2usb # graph: # sudo pycallgraph grml2usb /grml/isos/grml-small_2008.11.iso /dev/sdb1 diff --git a/debian/control b/debian/control index 8d01d35..ba485f8 100644 --- a/debian/control +++ b/debian/control @@ -7,9 +7,12 @@ Uploaders: Michael Prokop , Christian Hofstaedtler , Ulrich Dangel Build-Depends: asciidoc, + black, debhelper-compat (= 12), docbook-xsl, - xsltproc + flake8, + isort, + xsltproc, Standards-Version: 4.4.1 Homepage: https://grml.org/grml2usb/ Vcs-git: git://git.grml.org/grml2usb.git diff --git a/setup.cfg b/setup.cfg new file mode 100644 index 0000000..fe326c8 --- /dev/null +++ b/setup.cfg @@ -0,0 +1,2 @@ +[flake8] +ignore = E203, E501, W503 -- 2.1.4