diff --git a/src/download.js b/src/download.js index 9735586..c94ba2a 100644 --- a/src/download.js +++ b/src/download.js @@ -48,10 +48,9 @@ async function download (furl) { } let fn = path.join(musicdir, filename) - await asn.copyAsync(file.source, fn) - await fs.unlink(file.source) - let id3 = await asn.promiseExec(`id3 -a "${clean.artist}" -t "${clean.title}" "${fn}"`) + await asn.promiseExec(`ffmpeg -i "${file.source}" -metadata artist="${clean.artist}" -metadata title="${clean.title}" -codec copy "${fn}"`) + await fs.unlink(file.source) console.log('=> Done.') rl.close()