From c48005dbd75c985c8c163371af838ba35739894d Mon Sep 17 00:00:00 2001 From: kabeep Date: Fri, 10 May 2024 01:10:17 +0800 Subject: [PATCH] fix: avoid process continuous monitoring --- bin/cli.ts | 12 ++++++++---- src/utils/notify.ts | 8 ++++---- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/bin/cli.ts b/bin/cli.ts index b06d624..8440c71 100644 --- a/bin/cli.ts +++ b/bin/cli.ts @@ -97,7 +97,11 @@ pipeline( h: 'help', }) .parse() as ArgumentVector, -).catch((error: Exception) => { - console.log(`${error}`); - process.exit(1); -}); +) + .then(() => { + process.exit(0); + }) + .catch((error: Exception) => { + console.log(`${error}`); + process.exit(1); + }); diff --git a/src/utils/notify.ts b/src/utils/notify.ts index 78cf4d9..fbe7bfe 100644 --- a/src/utils/notify.ts +++ b/src/utils/notify.ts @@ -2,24 +2,24 @@ import Exception from '@kabeep/exception'; export class Info extends Exception { toString() { - return this.info('black.bgBlueBright'); + return this.info('black.bgBlue'); } } export class Success extends Exception { toString() { - return this.info('black.bgGreenBright'); + return this.info('black.bgGreen'); } } export class Warning extends Exception { toString() { - return this.info('black.bgYellowBright'); + return this.info('black.bgYellow'); } } export class Failure extends Exception { toString() { - return this.info('black.bgRedBright'); + return this.info('black.bgRed'); } }