Debian Codegraph @

scripts/check

raw symbols SCIP
1 #!/bin/shscip-shell filesystem . . `/bin/sh`.
2
3 file=
4
5 usage_message="Usage: check [OPTIONS]
6 OPTIONS:
7 --file=<filename> Specify file to check. If none specified, all
8 files in src/ and include/ will be checked.
9 "
10
11 run_checkpatchscip-shell shell shell-project 0.0.0 run_checkpatch().() {
12 nicescip-shell system . . nice. scripts/checkpatch.pl --terse --no-tree --strict --file "$1"
13 return $?
14 }
15
16 run_checksscip-shell shell shell-project 0.0.0 run_checks(). () {
17 if [scip-shell system . . `[`. ! -z "$file" ]; then
18 run_checkpatchscip-shell shell shell-project 0.0.0 run_checkpatch(). "${file}"
19 return $?
20 fi
21
22 findscip-shell system . . find. src/ include/ clients/ t/ \( -name "*.c" -o -name "*.h" \) -type f -print0 |
23 nicescip-shell system . . nice. xargs -0 --max-args 16 --max-procs $(nprocscip-shell system . . nproc.) \
24 scripts/checkpatch.pl --terse --no-tree --strict --file
25 return $?
26 }
27
28 mainscip-shell shell shell-project 0.0.0 main(). () {
29 for arg
30 do
31 opt=${arg%%=*}
32 var=${arg#*=}
33 case "$opt" in
34 --file)
35 file="$var" ;;
36 -h|--help)
37 printfscip-shell system . . printf. '%b' "$usage_message"; exit 1 ;;
38 *)
39 printfscip-shell system . . printf. '%b\n' "warn: unknown option $opt" >&2 ;;
40 esac
41 done
42
43 run_checksscip-shell shell shell-project 0.0.0 run_checks().
44 }
45
46 mainscip-shell shell shell-project 0.0.0 main(). "$@"