2024-11-29 16:16:56 +00:00
|
|
|
rwx_shellcheck_check() {
|
2024-11-25 17:39:25 +00:00
|
|
|
local root="${1}"
|
2024-11-29 11:17:39 +00:00
|
|
|
local file module modules path
|
2024-11-25 17:39:25 +00:00
|
|
|
file="$(mktemp)"
|
2024-11-25 19:46:09 +00:00
|
|
|
modules="$(sh_find_sh "${root}")"
|
2024-11-29 18:43:06 +00:00
|
|
|
rwx_ifs_set
|
2024-11-25 17:39:25 +00:00
|
|
|
for module in ${modules}; do
|
2024-11-29 11:17:39 +00:00
|
|
|
path="${root}/${module}"
|
|
|
|
echo ". \"${path}\"" >>"${file}"
|
2024-11-25 17:39:25 +00:00
|
|
|
done
|
2024-11-29 18:43:06 +00:00
|
|
|
rwx_ifs_unset
|
2024-11-25 17:39:25 +00:00
|
|
|
shellcheck \
|
|
|
|
--check-sourced \
|
|
|
|
--enable "all" \
|
|
|
|
--exclude "3043" \
|
|
|
|
--external-sources \
|
|
|
|
--shell "dash" \
|
|
|
|
"${file}"
|
|
|
|
rm "${file}"
|
|
|
|
}
|