const shell = require("shelljs");
const processShell = shell.exec(
`ffmpeg -i "https://pull-hls-l1-va01.tiktokcdn.com/game/stream-2998227837016342624_or4/playlist.m3u8?expire=1728613179&session_id=000-20240927021937E401758EF5D00A0AC325&sign=7aeab541c3ef8072d52a9fe799f8692b" -movflags use_metadata_tags -map_metadata 0 -metadata title="Chill chill kiếm kèo Warthunder" -metadata artist="bacgaucam" -metadata year="2024" -c copy "downloads/bacgaucam-927202491939.mp4" -n -stats -hide_banner -loglevel error`,
{ async: true }
);
setTimeout(() => {
// processShell.kill();
process.exit();
}, 20000);
my video only works when I use Ctrl+C to stop it. I’ve tried using process.exit()
, .kill(pid, "SIGINT")
, and the .kill()
method from the shell.exec()
reference, but none of them work
can anyone help? Thanks!