added new loop

This commit is contained in:
Daniel Sosnowski
2025-12-03 10:02:20 +01:00
parent 3b5e115675
commit c9cf5009c1

View File

@@ -19,25 +19,24 @@ then
for subscription in "${subscriptionList[@]}" for subscription in "${subscriptionList[@]}"
do do
for path in "$subscription/httpdocs/shopsystem/application/cache/boxes"* "$subscription/httpdocs/shopsystem/appcation/cache/smarty_compiled"
if [[ -d "$subscription/httpdocs/shopsystem/application/cache/boxes" ]]
then
cd "$subscription/httpdocs/shopsystem/application/cache/boxes"
fi
echo -e "Czyszczę cache w subskrybcji $subscription...\n"
ls -1 > "/tmp/dirList.txt"
readarray -t dirList < /tmp/dirList.txt
for dir in "${dirList[@]}"
do do
if [[ -d "$dir" ]] cd "$path"
then echo -e "Czyszczę cache w subskrybcji $subscription...\n"
echo -e "Czyszczenie $dir...\n" ls -1 > "/tmp/dirList.txt"
cd "$dir" readarray -t dirList < /tmp/dirList.txt
ls -1 for dir in "${dirList[@]}"
cd .. do
fi if [[ -d "$dir" ]]
then
echo -e "Czyszczenie $dir...\n"
cd "$dir"
ls -1
cd ..
fi
done
cd "$vhostDir"
done done
cd "$vhostDir"
done done
fi fi