Closed Laezor closed 3 years ago
Hi I saw that cleartemp wasn't working in windows so I made it work for windows.
function clearTemp() { exec(**`${__dirname}/clear.bat`**, function(err, stdout, stderr) { if (err) { console.warn("Failed to clear temp folder!"); } else { console.log("Cleared temp folder"); } }); }
I made a batch file so every time cleartemp is called the batch file will run to clear the temp folder.
del "%cd%\temp\*" /s /f /q
batch file will be on the same folder that main.js is.
Thanks, this could be helpful to others!
Hi I saw that cleartemp wasn't working in windows so I made it work for windows.
I made a batch file so every time cleartemp is called the batch file will run to clear the temp folder.
batch file will be on the same folder that main.js is.