1
0
mirror of https://github.com/simple-icons/simple-icons.git synced 2024-12-26 01:13:41 +02:00

Add error logging to prepublish script

This commit is contained in:
Eric Cornelissen 2019-07-21 19:46:37 +01:00
parent ddd578c7ac
commit 77b4be945d

View File

@ -49,6 +49,7 @@ data.icons.forEach(icon => {
const indexTemplate = fs.readFileSync(indexTemplateFile, "utf8");
const { error, code } = minify(util.format(indexTemplate, icons.map(iconToKeyValue).join(',')));
if (error) {
console.error(error);
process.exit(1);
} else {
fs.writeFileSync(indexFile, code);