20 lines
372 B
Bash
20 lines
372 B
Bash
|
sh_shellcheck() {
|
||
|
local root="${1}"
|
||
|
local file module modules
|
||
|
file="$(mktemp)"
|
||
|
modules="$(sh_source_find "${root}")"
|
||
|
_sh_ifs_new
|
||
|
for module in ${modules}; do
|
||
|
echo ". \"${root}/${module}\"" >>"${file}"
|
||
|
done
|
||
|
_sh_ifs_pop
|
||
|
shellcheck \
|
||
|
--check-sourced \
|
||
|
--enable "all" \
|
||
|
--exclude "3043" \
|
||
|
--external-sources \
|
||
|
--shell "dash" \
|
||
|
"${file}"
|
||
|
rm "${file}"
|
||
|
}
|