From 5de8eda21c61fd7e1cf6b7e4ec6c9d98dae3e365 Mon Sep 17 00:00:00 2001 From: Leah Rowe Date: Tue, 3 Oct 2023 12:59:35 +0100 Subject: general code cleanup in shell scripts Signed-off-by: Leah Rowe --- include/option.sh | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'include') diff --git a/include/option.sh b/include/option.sh index 73a727e4..ffcc7e94 100755 --- a/include/option.sh +++ b/include/option.sh @@ -29,11 +29,8 @@ scan_config() "${_fail}" "scan_config ${confdir}: Cannot concatenate files" while read -r line ; do set ${line} 1>/dev/null 2>/dev/null || : - if [ "${1%:}" = "depend" ]; then - depend="${depend} ${2}" - else - eval "${1%:}=\"${2}\"" - fi + [ "${1%:}" = "depend" ] && depend="${depend} ${2}" && continue + eval "${1%:}=\"${2}\"" done << EOF $(eval "awk '${awkstr}' \"${revfile}\"") EOF -- cgit v1.2.1