-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrun-helper
executable file
·49 lines (47 loc) · 1.02 KB
/
run-helper
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#!/bin/sh
set -e
exe=
args=
env=
case "$1" in
flake8)
exe="$1"
;;
black)
exe="$1"
# for now, only check
args="--diff --quiet"
;;
pylint3|pylint)
exe="$1"
env="PYTHONPATH=."
# for now, only errors
args="-E --disable=no-member"
;;
*)
echo "run-helper black|flake8|pylint3|pylint"
exit 1
;;
esac
echo "= $exe ="
if [ -n "$env" ]; then
export "$env"
fi
for i in ./reviewtools/*py \
./reviewtools/tests/*py \
./bin/snap-review \
./bin/create-snap-declaration \
./bin/dump-tool \
./bin/get-base-declaration \
./bin/store-query \
./bin/rock-check-notices \
./bin/rock-updates-available \
./bin/snap-updates-available \
./bin/snap-check-* \
./bin/snap-verify-* ; do
if echo "$i" | grep -q 'snap-check-notices\|rock-check-notices' ; then
continue # shell
fi
echo "Checking $i"
"$exe" $args "$i"
done