Merge output format to mp4/webm/mov

This commit is contained in:
Supositware 2022-09-10 09:34:57 +02:00
parent a1f995855d
commit cdebcd92a0

View file

@ -10,7 +10,7 @@ export default {
};
async function downloadVideo(urlArg, output, format = 'bestvideo*+bestaudio/best') {
await new Promise((resolve, reject) => {
exec(`./bin/yt-dlp -f ${format} "${urlArg}" -o "${os.tmpdir()}/${output}.%(ext)s" --force-overwrites --no-playlist`, (err, stdout, stderr) => {
exec(`./bin/yt-dlp -f ${format} "${urlArg}" -o "${os.tmpdir()}/${output}.%(ext)s" --force-overwrites --no-playlist --merge-output-format=mp4/webm/mov`, (err, stdout, stderr) => {
if (err) {
reject(stderr);
}