flarecms 0.2.6 → 0.2.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6693,7 +6693,7 @@ async function createPluginCommand() {
6693
6693
  s3.start(`Creating ${import_picocolors.default.cyan(pluginNameHuman)}...`);
6694
6694
  try {
6695
6695
  cpSync(resolve(templateBase, "starter-plugin"), paths.targetPlugin, { recursive: true });
6696
- cpSync(resolve(templateBase, "starter-playground"), paths.targetPlayground, { recursive: true });
6696
+ cpSync(resolve(templateBase, "playground"), paths.targetPlayground, { recursive: true });
6697
6697
  const placeholders = {
6698
6698
  "{{PLUGIN_NAME}}": pluginPackageName,
6699
6699
  "{{PLUGIN_ID}}": pluginId,
package/dist/cli/index.js CHANGED
@@ -6694,7 +6694,7 @@ async function createPluginCommand() {
6694
6694
  s3.start(`Creating ${import_picocolors.default.cyan(pluginNameHuman)}...`);
6695
6695
  try {
6696
6696
  cpSync(resolve(templateBase, "starter-plugin"), paths.targetPlugin, { recursive: true });
6697
- cpSync(resolve(templateBase, "starter-playground"), paths.targetPlayground, { recursive: true });
6697
+ cpSync(resolve(templateBase, "playground"), paths.targetPlayground, { recursive: true });
6698
6698
  const placeholders = {
6699
6699
  "{{PLUGIN_NAME}}": pluginPackageName,
6700
6700
  "{{PLUGIN_ID}}": pluginId,
@@ -6755,8 +6755,18 @@ async function mcpCommand(args) {
6755
6755
  }
6756
6756
 
6757
6757
  // src/cli/index.ts
6758
+ import { readFileSync as readFileSync2 } from "fs";
6759
+ import { resolve as resolve2, dirname } from "path";
6760
+ import { fileURLToPath as fileURLToPath2 } from "url";
6761
+ var __dirname2 = dirname(fileURLToPath2(import.meta.url));
6762
+ var pkg = JSON.parse(readFileSync2(resolve2(__dirname2, "../../package.json"), "utf8"));
6763
+ var version = pkg.version;
6758
6764
  async function main() {
6759
6765
  const args = process.argv.slice(2);
6766
+ if (args.includes("-v") || args.includes("--version") || args[0] === "version") {
6767
+ console.log(version);
6768
+ process.exit(0);
6769
+ }
6760
6770
  if (args[0] === "mcp") {
6761
6771
  await mcpCommand(args.slice(1));
6762
6772
  } else if (args[0] === "plugin" && args[1] === "create") {
@@ -6764,7 +6774,7 @@ async function main() {
6764
6774
  } else if (args.length === 0 || args[0] === "create") {
6765
6775
  await createProjectCommand();
6766
6776
  } else {
6767
- console.log("Unknown command. Available commands: create, plugin create, mcp");
6777
+ console.log("Unknown command. Available commands: create, plugin create, mcp, version");
6768
6778
  process.exit(1);
6769
6779
  }
6770
6780
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flarecms",
3
- "version": "0.2.6",
3
+ "version": "0.2.7",
4
4
  "license": "MIT",
5
5
  "description": "FlareCMS Monorepo: A lightweight CMS for the AI era.",
6
6
  "files": [