Adapt to new bot structure

This commit is contained in:
Marco Realacci 2024-04-04 23:24:06 +02:00
parent ff7e08ada9
commit 3f84e1d831
3414 changed files with 41525 additions and 709 deletions

View file

@ -0,0 +1,17 @@
#!/bin/bash
SEARCHDIR="./Ingegneria del Software/"
echo "Invalid URLs:"
for img in `grep "img" "$SEARCHDIR" -R | sed -E 's/^(.*?)\.txt\:img\=//'`; do
img=$(echo "$img"|tr -d '\n'|tr -d '\r')
curl -I "$img" 2>/dev/null | \
grep -i "Content-Type: image/" >/dev/null
if [ "$?" -ne 0 ]; then
(
cd "$SEARCHDIR"
grep "$img" . -R
)
fi
done