distribution and site management

This commit is contained in:
Clément GOUIN
2019-07-10 15:07:32 +02:00
parent 682e84914c
commit 2701ee39e5
14 changed files with 7287 additions and 30 deletions
+3 -4
View File
@@ -97,11 +97,10 @@ svn.commands.checkout(FA_SVG_FOLDER_URL, svgDir, (err) => {
console.log(`\t\t${type}: ${Object.keys(svgs[type]).length} SVGs`);
});
const argIndex = process.argv.indexOf('--output');
const output = (argIndex === -1 || !process.argv[argIndex + 1]) ? path.join(buildDir, 'svg_list.json') : process.argv[argIndex + 1];
fs.writeFileSync(output, JSON.stringify(svgs), {encoding: 'utf8'});
const output = path.join(__dirname, 'svg_list.json');
fs.writeFileSync(output, JSON.stringify(svgs, null, 4), {encoding: 'utf8'});
console.log(`\tSVG list saved at "${output}"`);
});
});