diff --git a/dev_requirements.txt b/dev_requirements.txt --- a/dev_requirements.txt +++ b/dev_requirements.txt @@ -6,3 +6,4 @@ pytest-localserver < 0.6 mock < 3.1 Sphinx < 1.9 WebTest < 2.1 +isort == 4.3.21 diff --git a/scripts/whitespacecleanup.sh b/scripts/whitespacecleanup.sh --- a/scripts/whitespacecleanup.sh +++ b/scripts/whitespacecleanup.sh @@ -17,4 +17,7 @@ sed -i -e 's|^\([^ /].*,\)\([^ ]\)|\1 \2 hg mani | xargs chmod -x hg loc 'set:!binary()&grep("^#!")&!(**_tmpl.py)&!(**/template**)' | xargs chmod +x +# isort is installed from dev_requirements.txt +isort --line-width 160 --wrap-length 160 --lines-after-imports 2 `hg loc '*.py'` + hg diff