Mercurial > kallithea
changeset 7810:5698307382de
scripts: introduce import cleanup using isort
author | Mads Kiilerich <mads@kiilerich.com> |
---|---|
date | Wed, 07 Aug 2019 00:22:56 +0200 |
parents | cbb85dc11e3a |
children | 0a277465fddf |
files | dev_requirements.txt scripts/whitespacecleanup.sh |
diffstat | 2 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/dev_requirements.txt Sun Aug 04 01:08:08 2019 +0200 +++ b/dev_requirements.txt Wed Aug 07 00:22:56 2019 +0200 @@ -6,3 +6,4 @@ mock < 3.1 Sphinx < 1.9 WebTest < 2.1 +isort == 4.3.21
--- a/scripts/whitespacecleanup.sh Sun Aug 04 01:08:08 2019 +0200 +++ b/scripts/whitespacecleanup.sh Wed Aug 07 00:22:56 2019 +0200 @@ -17,4 +17,7 @@ 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