Debian Codegraph @

check

raw symbols SCIP
1 #!/bin/sh
2
3 set -e
4
5 if [ $# -lt 1 ]
6 then
7 $0 coverage
8 $0 typecheck
9 $0 qa
10 exit 0
11 fi
12
13 PYTHON="${PYTHON:-python3}"
14 COVERAGE="${COVERAGE:-python3-coverage}"
15
16 export PYTHONDEVMODE=1
17
18 SUBCMD=$1
19 shift 1
20
21 case $SUBCMD in
22 "tests")
23 $PYTHON -m unittest discover -s tests
24 ;;
25 "coverage")
26 $COVERAGE run --source=lesana -m unittest discover -s tests
27 $COVERAGE report -m
28 ;;
29 "qa")
30 flake8 --select=E,F,W,C90,E123 --ignore=W503 lesana tests scripts
31 isort --check-only --diff .
32 if which doc8
33 then
34 doc8 .
35 fi
36 ;;
37 "typecheck")
38 mypy lesana
39 ;;
40 "static")
41 bandit --recursive --number=3 -lll -iii .
42 ;;
43 *)
44 echo "No such subcommand $SUBCMD"
45 ;;
46 esac