diff --git a/src/scripts/build-themes.ts b/src/scripts/build-themes.ts index 7c1aeae..4280f2c 100644 --- a/src/scripts/build-themes.ts +++ b/src/scripts/build-themes.ts @@ -47,8 +47,12 @@ function main(): void { printE(e); } - // Make sure themes dir exists - fs.mkdirSync(themesDir); + try { + // Make sure themes dir exists + fs.mkdirSync(themesDir); + } catch { + } + // Empty the themes dir fs.readdirSync(themesDir).forEach(file => { fs.unlinkSync(path.join(themesDir, file));