ceph-docker sources a lot of files so to prevent warning from shellcheck
we add the option '-x' to source.
Follow 'source' statements even when the file is not specified as input.
By default, shellcheck will only follow files specified on the command
line (plus /dev/null). This option allows following any file the
script may source.
Signed-off-by: Sébastien Han <seb@redhat.com>
while read -r filename; do
if [[ -z "$IGNORE_THESE_CODES" ]]
then
- shellcheck "$filename";
+ shellcheck -x "$filename";
else
- shellcheck -e "$IGNORE_THESE_CODES" "$filename";
+ shellcheck -x -e "$IGNORE_THESE_CODES" "$filename";
fi
done
return $?