We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f69f910 commit b118b00Copy full SHA for b118b00
apps/cli/src/index.ts
@@ -43,4 +43,15 @@ registerRunCommand(program);
43
registerSendCommand(program);
44
registerShellCommand(program);
45
46
+// Global error handling
47
+process.on("uncaughtException", (err) => {
48
+ if (process.env.NODE_ENV === "development") {
49
+ console.error(err);
50
+ } else {
51
+ // in production, only print the error message, not the stack trace
52
+ console.error(err.message);
53
+ }
54
+ process.exit(1);
55
+});
56
+
57
program.parse();
0 commit comments