I am trying to loop through directories within a given folder and I want to skip a particular directory name. I have written this bash script to do it, but this is giving me errors. Please tell me where I am going wrong:
for f in *
do
if [ -d "$f" ]; then
if [ -d "TEST"];then
echo "skip TEST directory"
continue
fi
echo "$f"
fi
done
I want to skip TEST directory.