Files
Server-scripts/ffmpeg.sh
T
2026-09-14 09:20:47 +02:00

30 lines
575 B
Bash
Executable File

#!/bin/bash
if [ -z "$1" ]; then
echo "Usage: $0 <Series> [additional ffmpeg_handling.py args...]"
exit 1
fi
series="$1"
shift
for d in */; do
[ -d "$d" ] || continue
name="${d%/}"
# extract leading number (int or float)
if [[ $name =~ ([0-9]+([.,][0-9]+)?) ]]; then
num="${BASH_REMATCH[1]}"
else
continue
fi
echo $d $num
~/git/serverhost/.venv/bin/python \
~/git/serverhost/ffmpeg_handling.py \
ms "$name" \
--override \
-k grouping \
-v "$series #$num" \
"$@"
done