UNPKG

create-zephyr-apps

Version:

A CLI tool to create web applications using Zephyr.

20 lines (17 loc) 673 B
import fs from 'node:fs'; import path from 'node:path'; import { fileURLToPath } from 'node:url'; const packageRoot = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..'); const packageVersion = JSON.parse( fs.readFileSync(path.join(packageRoot, 'package.json'), 'utf8') ).version; for (const relativePath of [ '.codex-plugin/plugin.json', '.claude-plugin/plugin.json', '.cursor-plugin/plugin.json', ]) { const manifestPath = path.join(packageRoot, relativePath); const manifest = JSON.parse(fs.readFileSync(manifestPath, 'utf8')); manifest.version = packageVersion; fs.writeFileSync(manifestPath, `${JSON.stringify(manifest, null, 2)}\n`); }