This commit is contained in:
notgne2 2021-01-27 00:46:31 -07:00
parent cdcaf0e708
commit 2a93072e7c
No known key found for this signature in database
GPG Key ID: BB661E172B42A7F8

View File

@ -115,7 +115,9 @@ async function thing() {
album, artist, title, trackNum, file, image,
} of files) {
const path = `${os.homedir()}/Music/${album}/${artist} - ${title}.mp3`;
await fs.ensureDir(`${os.homedir()}/Music/${album}`);
try {
await fs.mkdir(`${os.homedir()}/Music/${album}`, { recursive: true });
} catch (err) { }
if (!(await fs.exists(path))) {
console.log(`Encoding to: ${path}`);