21 lines
412 B
Bash
Executable file
21 lines
412 B
Bash
Executable file
#!/bin/sh -e
|
|
|
|
if [ "$1" = '--fix' ]; then
|
|
(
|
|
set -x
|
|
black .
|
|
isort --profile black .
|
|
autoflake --in-place --recursive .
|
|
mypy . || : # ignore
|
|
)
|
|
exit
|
|
fi
|
|
|
|
error=0
|
|
|
|
(set -x; black --check .) || error=$?
|
|
(set -x; isort --profile black --check .) || error=$?
|
|
(set -x; autoflake --check --recursive . | uniq) || error=$?
|
|
(set -x; mypy .) || : # ignore
|
|
|
|
exit "$error"
|