@@ -113,7 +113,7 @@ fn_wallbash() {
113113 # We don't want themes to launch the exec_command or any arbitrary codes
114114 # To enable this we should have a *.dcol file as a companion to the theme file
115115 # IFS=':' read -r -a wallbash_dirs_array <<<"$wallbash_dirs"
116- local template_name
116+ local template_name
117117 template_name=" ${template##*/ } "
118118 template_name=" ${template_name% .* } "
119119 dcolTemplate=$( find -H " ${wallbash_dirs_array[@]} " -type f -path " */theme*" -name " ${template_name} .dcol" 2> /dev/null | awk ' !seen[substr($0, match($0, /[^/]+$/))]++' )
@@ -125,10 +125,10 @@ fn_wallbash() {
125125 fi
126126 fi
127127
128- if [[ " ${LOG_LEVEL} " == " debug" ]]; then
129- print_log -sec " wallbash" -stat " Template:" " ${template} "
130- print_log -sec " wallbash" -stat " Wallbash Directories:" " ${wallbash_dirs_array[*]} "
131- print_log -sec " wallbash" -stat " Wallbash Scripts:" " ${WALLBASH_SCRIPTS} "
128+ if [[ " ${LOG_LEVEL} " == " debug" ]]; then
129+ print_log -sec " wallbash" -stat " Template:" " ${template} "
130+ print_log -sec " wallbash" -stat " Wallbash Directories:" " ${wallbash_dirs_array[*]} "
131+ print_log -sec " wallbash" -stat " Wallbash Scripts:" " ${WALLBASH_SCRIPTS} "
132132 fi
133133
134134 # shellcheck disable=SC1091
287287
288288# Single template mode
289289if [ -n " ${single_template} " ]; then
290- fn_wallbash " ${single_template} "
290+ fn_wallbash " ${single_template} " " ${wallbashDirs[@]} "
291291 exit 0
292292fi
293293
@@ -310,13 +310,12 @@ if [ "${enableWallDcol}" -eq 0 ] && [[ "${reload_flag}" -eq 1 ]]; then
310310 done < <( find -H " ${wallbashDirs[@]} " -type f -path " */theme*" -name " *.dcol" 2> /dev/null | awk ' !seen[substr($0, match($0, /[^/]+$/))]++' )
311311
312312 # Process templates in parallel
313- parallel fn_wallbash {} " $wallbashDirs [@]" ::: " ${deployList[@]} " || true
314-
313+ parallel fn_wallbash {} " ${wallbashDirs[@]} " ::: " ${deployList[@]} " || true
315314
316315elif [ " ${enableWallDcol} " -gt 0 ]; then
317316 print_log -sec " wallbash" -stat " apply ${dcol_mode} colors" " Wallbash theme"
318317 # This is the reason we avoid SPACES for the wallbash template names
319- find -H " ${wallbashDirs[@]} " -type f -path " */theme*" -name " *.dcol" 2> /dev/null | awk ' !seen[substr($0, match($0, /[^/]+$/))]++' | parallel fn_wallbash {} " ${wallbashDirs[@]} " || true
318+ find -H " ${wallbashDirs[@]} " -type f -path " */theme*" -name " *.dcol" 2> /dev/null | awk ' !seen[substr($0, match($0, /[^/]+$/))]++' | parallel fn_wallbash {} " ${wallbashDirs[@]} " || true
320319fi
321320
322321# Process "always" templates in parallel
0 commit comments