#!/bin/bash -e if ! command -v shellcheck > /dev/null; then echo "E: Please install the program 'shellcheck' prior to executing this script." exit 1 fi # This script is supposed to be in the scripts subdirectory TOPDIR=$(realpath --relative-to=. "$(dirname "$0")/..") # Exclude tracking includes and don't complain about include paths SHELLCHECK_OPTS="--exclude=SC1090,SC1091" export SHELLCHECK_OPTS # Check if files are specified on the command line. If so, only use those. if [ $# -gt 0 ]; then case "$1" in -h|--help*) cat <