once last check prior to exiting script

This commit is contained in:
Heavybullets8 2022-08-10 20:36:24 -06:00
parent 83d65a2a8f
commit 36002c59fb

View File

@ -15,6 +15,7 @@ while_status=$(cli -m csv -c 'app chart_release query name,update_available,huma
echo "$while_status" > temp.txt echo "$while_status" > temp.txt
rm trigger &>/dev/null rm trigger &>/dev/null
delay=2 delay=2
final_check=0
while true while true
do do
if [[ -f trigger ]]; then if [[ -f trigger ]]; then
@ -44,9 +45,10 @@ do
((it++)) ((it++))
((proc_count++)) ((proc_count++))
done done
elif [[ ${#processes[@]} != 0 ]]; then # Wait for all processes to finish elif [[ $proc_count != 0 ]]; then # Wait for all processes to finish
sleep $delay sleep $delay
else # All processes must be completed, break out of loop else # All processes must be completed, break out of loop
[[ $final_check == 0 ]] && ((final_check++)) && continue
break break
fi fi
done done