jenkins-bot has submitted this change and it was merged.
Change subject: tox entry point to run pep8 1.4.6 ......................................................................
tox entry point to run pep8 1.4.6
The Wikimedia CI tests are hardcoded to run pep8==1.4.6. Introduce tox to let developers easily redefine whatever command they need.
Not using flake8 since the repo does not pass pyflakes and others. But it will be easy to switch to it later on.
Pin pep8 to 1.4.6 to match the version that has been running on Wikimedia CI (Ubuntu Precise). Move content of .pep8 to tox.ini section [pep8]. That is properly recognized by pep8 1.4.6. Ignore /.tox
Bug: T55354 Change-Id: I70e4a843dae5a7ebab6485e1abab2b124535f193 --- M .gitignore D .pep8 A tox.ini 3 files changed, 13 insertions(+), 4 deletions(-)
Approvals: John Vandenberg: Looks good to me, approved jenkins-bot: Verified
diff --git a/.gitignore b/.gitignore index 29cd0f2..ad22c18 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ +/.tox *.bak *.pyc logs* diff --git a/.pep8 b/.pep8 deleted file mode 100644 index 100c9aa..0000000 --- a/.pep8 +++ /dev/null @@ -1,4 +0,0 @@ -[pep8] -ignore = E122,E127,E241,E226,E502,W602 -exclude = ./catimages.py,./wiktionary.py,./wiktionary/*,./tests/*,./userinterfaces/*,./commonsdelinker/*,./families/*,./maintenance/*,./pywikibot/*,./externals/* -max_line_length = 256 diff --git a/tox.ini b/tox.ini new file mode 100644 index 0000000..33bd621 --- /dev/null +++ b/tox.ini @@ -0,0 +1,12 @@ +[tox] +skipsdist = True +envlist = lint + +[testenv:lint] +commands = pep8 +deps = pep8==1.4.6 + +[pep8] +ignore = E122,E127,E241,E226,E502,W602 +exclude = ./catimages.py,./wiktionary.py,./wiktionary/*,./tests/*,./userinterfaces/*,./commonsdelinker/*,./families/*,./maintenance/*,./pywikibot/*,./externals/*,./.tox +max_line_length = 256
pywikibot-commits@lists.wikimedia.org