javascript - nodejs adding double quotes to command arguments? -
example:
ffmpeg -i test.mkv -metadata title="test 123" -c copy temp.mkv
ffmpeg sees ""test 123""
. happens spawn() , execfile()
if run same command in windows shell ffmpeg sees correctly "test 123"
so what's nodejs?
here's nodejs code:
var process = spawn('ffmpeg', [ '-i', infile, '-metadata', 'title="test 123"', '-c', 'copy', outfile ]);
you need switch "title='test 123'"
since double quotes have precedence on single quotes. stdin
should parse right title="test 123"
.
Comments
Post a Comment