ffmpeg batch script for video resizing - improved
Is it intended that date is executed separately for each input, or should all converted files have consistent names (for that use of the script)?  It's certainly worth a comment explaining your choice.

I'm not a fan of the big space in the redirection &gt;     /dev/null - that makes it harder to parse.

This if/else chain looks a little clumsy:


if [ "${rotation}" -eq 0 ] || [ "${rotation}" -eq 180 ]
then
    scaling="-1:720"
elif [ "${rotation}" -eq 90 ] || [ "${rotation}" -eq 270 ]
then
    scaling="720:-1"
else
    fail "-&gt; Unhandled rotation"
    return
fi



When testing a single value against various possibilities, it tends to be neater using case:

case "$rotation" in
    0|180) scaling="-1:720" ;;
    90|270) scaling="720:-1" ;;
    *) fail "-&gt; Unhandled rotation '$rotation'"; return ;;
esac


(I also added extra information in the failure case, that may help diagnose problem input files).