How to escape this in the bash script?
- by allenskd
I'm trying to complete a batch of 3 videos to leave it there till morning processing but it seems there are special characters in it... I try it "raw" in the terminal and it works but in bash script it stops working
Example:
args1="-r 29.97 -t 00:13:30 -vsync 0 -vpre libx264-medium -i"
args12="-r 29.97 -ss 00:40:30 -vsync 0 -vpre libx264-medium -i"
args2="[in] scale=580:380 [T1],[T1] pad=720:530:0:50 (other arguments with lots of [ and ]"
In the output it says
Unable to find a suitable output format for 'scale=580:380' not sure why... like I said, the command runs fine in the command-line, just not in the script
/usr/local/bin/ffmpeg "$args1" "${file}" -vf "$args2" "$args3" "${args[0]}_${startingfrom}_0001_02.mp4"