From b60c4c84d083f161c69f47fee40f6015fa64b975 Mon Sep 17 00:00:00 2001 From: Ana Hobden Date: Thu, 5 Jan 2023 08:55:25 -0800 Subject: [PATCH] Be more friendly to light terminals (#149) * Be more friendly to light terminals * Remove all white() * Fix botched merge * fmt Co-authored-by: Linus Heckemann --- src/cli/interaction.rs | 2 +- src/cli/subcommand/install.rs | 4 +--- src/plan.rs | 4 ++-- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/src/cli/interaction.rs b/src/cli/interaction.rs index 6bc7a28..f66d397 100644 --- a/src/cli/interaction.rs +++ b/src/cli/interaction.rs @@ -18,7 +18,7 @@ pub(crate) async fn confirm(question: impl AsRef, default: bool) -> eyre::R {are_you_sure} ({yes}/{no}): \ ", question = question.as_ref(), - are_you_sure = "Proceed?".bright_white().bold(), + are_you_sure = "Proceed?".bold(), no = "N".red().bold(), yes = "y".green(), ); diff --git a/src/cli/subcommand/install.rs b/src/cli/subcommand/install.rs index 095c8ee..4046340 100644 --- a/src/cli/subcommand/install.rs +++ b/src/cli/subcommand/install.rs @@ -196,9 +196,7 @@ impl CommandExecute for Install { "\ {message}\n\ ", - message = "Partial Nix install was uninstalled successfully!" - .white() - .bold(), + message = "Partial Nix install was uninstalled successfully!".bold(), ); } } else { diff --git a/src/plan.rs b/src/plan.rs index a040c5b..fc27640 100644 --- a/src/plan.rs +++ b/src/plan.rs @@ -79,7 +79,7 @@ impl InstallPlan { plan_settings = planner .settings()? .into_iter() - .map(|(k, v)| format!("* {k}: {v}", k = k.bold().white())) + .map(|(k, v)| format!("* {k}: {v}", k = k.bold())) .collect::>() .join("\n"), actions = actions @@ -180,7 +180,7 @@ impl InstallPlan { plan_settings = planner .settings()? .into_iter() - .map(|(k, v)| format!("* {k}: {v}", k = k.bold().white())) + .map(|(k, v)| format!("* {k}: {v}", k = k.bold())) .collect::>() .join("\n"), actions = actions