rebuild array

This commit is contained in:
Heavybullets8 2022-08-21 21:58:24 -06:00
parent ba17b0dd13
commit bc9fed707e

View File

@ -34,8 +34,7 @@ do
printf '%s\0' "${containers[@]}" | grep -Fxqz -- "$(echo "$search" | grep "$pod" | awk '{print $4}' | tr -d " \t\r ")" && continue
containers+=("$(echo "$search" | grep "$pod" | awk '{print $4}' | tr -d " \t\r ")")
done
readarray -t containers <<<"${containers[*]}"
readarray -td, containers <<<"${containers[@]}"; declare -p containers;
case "${#containers[@]}" in
0)
echo -e "No containers available\nAre you sure the application in running?"