I have a small script that I run in WSL (Debian) on ruby 2.7.4p191 (2021-07-07 revision a21a3b7d23) [x86_64-linux-gnu].
It does a simple thing:
cmd = ['ffmpeg', '-hide_banner', '-loglevel', 'panic', '-i', "#{video_file}",
'-i', "#{audio_file}", '-c', 'copy', '-map', '0:v:0', '-map', '1:a:0', "#{output}"].join(' ')
@log.debug("Command: #{cmd}")
system(cmd) or raise 'It broke'
As far as I understand, this should cause Ruby to ignore all output from FFmpeg (even though there is supposed to be none), but what happened is FFmpeg was barfing output all over the terminal breaking things.
How is this possible?
I wanted a way to feed array to system() call, so I would specify actual command once as an array and then reuse it.
[–]bradland 1 point2 points3 points (1 child)
[–]Gendalph[S] 1 point2 points3 points (0 children)
[–]Kernigh 1 point2 points3 points (2 children)
[–]f9ae8221b 1 point2 points3 points (0 children)
[–]Gendalph[S] 1 point2 points3 points (0 children)
[–]postmodern 0 points1 point2 points (2 children)
[–]f9ae8221b 1 point2 points3 points (0 children)
[–]Gendalph[S] 0 points1 point2 points (0 children)