aboutsummaryrefslogtreecommitdiff
path: root/shellcheck.sh
blob: 7c8dc6ec5b92e922866bcb2536d807b08f00e676 (plain) (blame)
1
2
3
4
5
6
7
8
9
#!/bin/sh

find "$(dirname "$0")" -maxdepth 1 -type f -executable -exec \
    sh -c '
if head -n1 "$1" | egrep -q "sh$"; then
    echo "====== CHECKING $1 ======";
    shellcheck "$1";
fi
    ' shell {} \;