aboutsummaryrefslogtreecommitdiffstats
path: root/maintenance/metrics.sh
blob: 760df0316abac784d77530c83f0eac6411419795 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/bin/sh

basedir="$(dirname "$0")"
[ "$(echo "$basedir" | cut -c1)" = '/' ] || basedir="$PWD/$basedir"

[ $# -ge 1 ] || {
	echo "Usage: $0 [CLOC-OPTS] DIRECTORY" >&2
	exit 1
}

set -e

cd "$basedir/.."

cloc --exclude-dir="build,dist,.pybuild,release-archives,icons,__pycache__,submodules,awlsim_cython,pyprofibus" \
	--read-lang-def="${basedir}/../misc/cloc-lang.txt" \
	--exclude-lang='ASP.Net,IDL,D' \
	--quiet --progress-rate=0 \
	"$@"
bues.ch cgit interface