]>
git.ipfire.org Git - thirdparty/systemd.git/blob - coccinelle/run-coccinelle.sh
3 top
="$(git rev-parse --show-toplevel)"
4 files
="$(git ls-files ':/*.[ch]')"
9 args
="$args --in-place"
14 if ! parallel
-h >/dev
/null
; then
15 echo 'Please install GNU parallel (package "parallel")'
19 for SCRIPT
in ${@-$top/coccinelle/*.cocci} ; do
20 echo "--x-- Processing $SCRIPT --x--"
22 echo "+ spatch --sp-file $SCRIPT $args ..."
23 parallel
--halt now
,fail
=1 --keep-order --noswap --max-args=20 \
24 spatch
--sp-file $SCRIPT $args ::: $files \
25 2>"$TMPFILE" ||
cat "$TMPFILE"
26 echo -e "--x-- Processed $SCRIPT --x--\n"