give until loop its own variable..
This commit is contained in:
parent
31285a8d68
commit
eddf0937c4
@ -78,11 +78,12 @@ do
|
|||||||
if [[ "$proc_count" -ge "$update_limit" ]]; then
|
if [[ "$proc_count" -ge "$update_limit" ]]; then
|
||||||
sleep 3
|
sleep 3
|
||||||
elif [[ $it -lt ${#array[@]} ]]; then
|
elif [[ $it -lt ${#array[@]} ]]; then
|
||||||
until [[ "$proc_count" -ge 2 || $it -ge ${#array[@]} ]];
|
loop=0
|
||||||
|
until [[ "$loop" -ge 2 || $it -ge ${#array[@]} ]];
|
||||||
do
|
do
|
||||||
update_apps "${array[$it]}" &
|
update_apps "${array[$it]}" &
|
||||||
processes+=($!)
|
processes+=($!)
|
||||||
((proc_count++))
|
((loop++))
|
||||||
((it++))
|
((it++))
|
||||||
done
|
done
|
||||||
elif [[ $proc_count != 0 ]]; then # Wait for all processes to finish
|
elif [[ $proc_count != 0 ]]; then # Wait for all processes to finish
|
||||||
|
Loading…
Reference in New Issue
Block a user