Trouble with script quoting
Posted: 09 Aug 2020 08:31
I'm trying to create a CFA to convert mp4 videos with ffmpeg and while I managed to make the conversion with the following command line:
I cannot get the CFA (and all its variations of quoting I tried so far) to work:
The "yyy.mp4" is static at the moment and would only work for one file right now but once the command works, I plan to dynamically adapt the name to "<base>_fix.mp4" for each file.
Naturally, both source and destination paths can contain spaces and the quoting above was copied from an Irfanview CFA that had trouble with such filenames.
Code: Select all
C:\Program Files\ffmpeg\bin>ffmpeg.exe -err_detect ignore_err -i D:\Temp\xxx.mp4 -c copy -an D:\Temp\yyy.mp4
Code: Select all
|"Convert CCTV w/ ffmpeg" mp4>::foreach ($item, <pfaitems>) {run """C:\Program Files\ffmpeg\bin\ffmpeg.exe -err_detect ignore_err -i ""$item"" -c copy -an D:\Temp\yyy.mp4"""}
Naturally, both source and destination paths can contain spaces and the quoting above was copied from an Irfanview CFA that had trouble with such filenames.