@fireberry/cli 0.0.5-beta.6 → 0.0.5-beta.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.
@@ -30,6 +30,7 @@ program.parseAsync(process.argv).catch((err) => {
30
30
  : typeof err === 'string'
31
31
  ? err
32
32
  : 'Unexpected error';
33
- console.error(chalk.red(errorMessage));
33
+ const formattedError = errorMessage.startsWith('Error:') ? errorMessage : `Error: ${errorMessage}`;
34
+ console.error(chalk.red(formattedError));
34
35
  process.exit(1);
35
36
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fireberry/cli",
3
- "version": "0.0.5-beta.6",
3
+ "version": "0.0.5-beta.7",
4
4
  "description": "Fireberry CLI tool",
5
5
  "type": "module",
6
6
  "author": "",
@@ -26,7 +26,7 @@ program
26
26
  .description("Create a new Fireberry app")
27
27
  .action(async (nameArgs?: string[]) => {
28
28
  const name = nameArgs ? nameArgs.join("-") : undefined;
29
- await runCreate({ name });
29
+ await runCreate({ name });
30
30
  });
31
31
 
32
32
  program.parseAsync(process.argv).catch((err: unknown) => {
@@ -35,6 +35,8 @@ program.parseAsync(process.argv).catch((err: unknown) => {
35
35
  : typeof err === 'string'
36
36
  ? err
37
37
  : 'Unexpected error';
38
- console.error(chalk.red(errorMessage));
38
+
39
+ const formattedError = errorMessage.startsWith('Error:') ? errorMessage : `Error: ${errorMessage}`;
40
+ console.error(chalk.red(formattedError));
39
41
  process.exit(1);
40
42
  });