Move flake8 configuration to setup.cfg
authorJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>
Tue, 16 Dec 2014 18:54:22 +0000 (19:54 +0100)
committerJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>
Tue, 16 Dec 2014 19:34:07 +0000 (20:34 +0100)
It will be used when calling flake8 from any directory in the project

Makefile
setup.cfg

index 524c5fcda6c5095ad47738d8b5e493eecee54053..71c8553d888f11625b6bb38b607f3a8607ba6e10 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -36,11 +36,7 @@ install: youtube-dl youtube-dl.1 youtube-dl.bash-completion youtube-dl.zsh youtu
        install -m 644 youtube-dl.fish $(DESTDIR)$(SYSCONFDIR)/fish/completions/youtube-dl.fish
 
 codetest:
-       FLAKE8_OUT=$$(flake8 --ignore E501 . | grep -v youtube_dl/extractor/__init__.py); \
-       if test -n "$$FLAKE8_OUT"; then \
-               echo "$$FLAKE8_OUT"; \
-               exit 1; \
-       fi
+       flake8 .
 
 test:
        #nosetests --with-coverage --cover-package=youtube_dl --cover-html --verbose --processes 4 test
index e57d130e37157aa3fa6081f6dae8bf3189e43ee2..8659b50699645c0f465dc00c21e62877b7b1c79a 100644 (file)
--- a/setup.cfg
+++ b/setup.cfg
@@ -1,2 +1,6 @@
 [wheel]
 universal = True
+
+[flake8]
+exclude = youtube_dl/extractor/__init__.py
+ignore = E501