mirror of
https://github.com/ben-grande/qusal.git
synced 2025-05-06 16:25:17 -04:00
fix: avoid operand evaluation as argument
Explicit end option parsing as the shell can be quite dangerous without it.
This commit is contained in:
parent
e42950376a
commit
1b2f1ba941
52 changed files with 196 additions and 189 deletions
|
@ -38,16 +38,16 @@ case "${find_tool}" in
|
|||
conf_files="$(${find_tool} . minion.d/ -e conf)"
|
||||
sls_files="$(${find_tool} . salt/ -d 2 -t f -e sls -e top -e jinja \
|
||||
-e j2 -e tmpl -e tst | sort -d)"
|
||||
files="${conf_files}\n${sls_files}"
|
||||
set -- ${conf_files} ${sls_files}
|
||||
;;
|
||||
find)
|
||||
conf_files="$(find minion.d/ -type f -name "*.conf")"
|
||||
sls_files="$(find salt/* -maxdepth 2 -type f \
|
||||
\( -name '*.sls' -o -name '*.top' -o -name '*.jinja' \
|
||||
-o -name '*.j2' -o -name '*.tmpl' -o -name '*.tst' \) | sort -d)"
|
||||
files="${conf_files}\n${sls_files}"
|
||||
set -- ${conf_files} ${sls_files}
|
||||
;;
|
||||
*) echo "Unsupported find tool" >&2; exit 1;;
|
||||
esac
|
||||
|
||||
exec salt-lint ${conf} ${files}
|
||||
exec salt-lint ${conf} "${@}"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue