From 928477e1cd9eb01ce8665316d80d82257404a582 Mon Sep 17 00:00:00 2001 From: "Md. Sazzad Hossain Sharkar" Date: Sat, 25 Nov 2023 20:53:42 +0600 Subject: [PATCH] enhance(commit.ts): improve push success message readability The success message for pushing commits now highlights the remote name with additional styling. This change enhances the readability and visual appeal of the success message when commits are pushed to a remote repository. --- out/cli.cjs | 18 ++++++++++++++---- src/commands/commit.ts | 6 ++++-- 2 files changed, 18 insertions(+), 6 deletions(-) diff --git a/out/cli.cjs b/out/cli.cjs index ddbc205..3d72a8f 100755 --- a/out/cli.cjs +++ b/out/cli.cjs @@ -33935,10 +33935,16 @@ ${source_default.grey("\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2 }); if (isPushConfirmedByUser && !eD2(isPushConfirmedByUser)) { const pushSpinner = de(); - pushSpinner.start(`${source_default.black.bold.bgBlue(` INFO `)} Running 'git push ${remotes[0]}...'`); + pushSpinner.start( + `${source_default.black.bold.bgBlue(` INFO `)} Running git push ${source_default.black.bold.bgBlue( + ` ${remotes[0]} ` + )}` + ); const { stdout: stdout2 } = await execa("git", ["push", "--verbose", remotes[0]]); pushSpinner.stop( - `${source_default.black.bold.bgGreen(` SUCCESS `)} Successfully pushed all commits to ${remotes[0]}.` + `${source_default.black.bold.bgGreen( + ` SUCCESS ` + )} Successfully pushed all commits to ${source_default.bold.blue.bgGreen(` ${remotes[0]} `)}.` ); if (stdout2) $e(stdout2); @@ -33953,12 +33959,16 @@ ${source_default.grey("\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2 }); if (!eD2(selectedRemote)) { const pushSpinner = de(); - pushSpinner.start(`${source_default.black.bold.bgBlue(` INFO `)} Running 'git push ${selectedRemote}...'`); + pushSpinner.start( + `${source_default.black.bold.bgBlue(` INFO `)} Running git push ${source_default.black.bold.bgBlue( + ` ${selectedRemote} ` + )}` + ); const { stdout: stdout2 } = await execa("git", ["push", selectedRemote]); pushSpinner.stop( `${source_default.black.bold.bgGreen( ` SUCCESS ` - )} Successfully pushed all commits to ${selectedRemote}.` + )} Successfully pushed all commits to ${source_default.bold.black.bgGreen(` ${selectedRemote} `)}.` ); if (stdout2) $e(stdout2); diff --git a/src/commands/commit.ts b/src/commands/commit.ts index ad7f973..80965c6 100644 --- a/src/commands/commit.ts +++ b/src/commands/commit.ts @@ -95,7 +95,9 @@ ${chalk.grey('—————————————————————— const { stdout } = await execa('git', ['push', '--verbose', remotes[0]]); pushSpinner.stop( - `${chalk.black.bold.bgGreen(` SUCCESS `)} Successfully pushed all commits to ${remotes[0]}.`, + `${chalk.black.bold.bgGreen( + ` SUCCESS `, + )} Successfully pushed all commits to ${chalk.bold.blue.bgGreen(` ${remotes[0]} `)}.`, ); // eslint-disable-next-line max-depth @@ -124,7 +126,7 @@ ${chalk.grey('—————————————————————— pushSpinner.stop( `${chalk.black.bold.bgGreen( ` SUCCESS `, - )} Successfully pushed all commits to ${selectedRemote}.`, + )} Successfully pushed all commits to ${chalk.bold.black.bgGreen(` ${selectedRemote} `)}.`, ); // eslint-disable-next-line max-depth