import path from 'path'; import {getCurrentDirPath, writeFileIfNotExists} from "../helpers.mjs"; const currentDir = getCurrentDirPath(import.meta.url); const ICONS_DIR = path.resolve(currentDir, '../../icons'); const iconNames = process.argv.slice(2); const iconSvgTemplate = ` `; const iconJsonTemplate = `{ "$schema": "../icon.schema.json", "tags": [ ], "categories": [ ] } `; iconNames.forEach(iconName => { writeFileIfNotExists(iconSvgTemplate, `${iconName}.svg`, ICONS_DIR); writeFileIfNotExists(iconJsonTemplate, `${iconName}.json`, ICONS_DIR); });