mirror of
https://github.com/Mastermindzh/examples.git
synced 2024-10-22 21:17:35 +02:00
18 lines
313 B
Bash
18 lines
313 B
Bash
#!/bin/bash
|
|
# will recursively remove ( and ) from all files
|
|
|
|
for d in /mnt/series/Smallville/*; do
|
|
if [ -d "$d" ]; then
|
|
echo ""
|
|
echo "=> moving to: $d"
|
|
cd "$d"
|
|
for f in *.*; do
|
|
echo "processing: $f"
|
|
des=$(echo "$f" | tr -d '()')
|
|
if [ "$f" != "$des" ]; then
|
|
mv "$f" "$des"
|
|
fi
|
|
done
|
|
fi
|
|
done
|