aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2010-02-09 16:04:28 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2010-02-09 16:04:28 +0000
commit82644188160641c6f9a5fcb573e9a0aa0726b8b2 (patch)
tree66b64d7b8475fa79c2b1542806c380f1f5b1bb42
parentbfba94957941bf45dda994473681fdb4c9e6bc57 (diff)
downloadpaludis-82644188160641c6f9a5fcb573e9a0aa0726b8b2.tar.gz
paludis-82644188160641c6f9a5fcb573e9a0aa0726b8b2.tar.xz
Show when not taking the best version
-rw-r--r--src/clients/cave/cmd_display_resolution.cc18
1 files changed, 13 insertions, 5 deletions
diff --git a/src/clients/cave/cmd_display_resolution.cc b/src/clients/cave/cmd_display_resolution.cc
index 3469806..7601ee3 100644
--- a/src/clients/cave/cmd_display_resolution.cc
+++ b/src/clients/cave/cmd_display_resolution.cc
@@ -571,20 +571,28 @@ namespace
is_upgrade = is_upgrade && (! is_reinstall) && (! is_downgrade);
is_reinstall = is_reinstall && (! is_downgrade);
+ std::string x(" ");
+ if (! decision.best())
+ x[0] = '-';
+
if (is_new && ! other_slots)
- cout << "n " << c::bold_blue();
+ cout << "n" << x << c::bold_blue();
else if (is_new && other_slots)
- cout << "s " << c::bold_blue();
+ cout << "s" << x << c::bold_blue();
else if (is_upgrade)
- cout << "u " << c::blue();
+ cout << "u" << x << c::blue();
else if (is_reinstall)
- cout << "r " << c::yellow();
+ cout << "r" << x << c::yellow();
else if (is_downgrade)
- cout << "d " << c::bold_yellow();
+ cout << "d" << x << c::bold_yellow();
else
throw InternalError(PALUDIS_HERE, "not new, upgrade, reinstall or downgrade. huh?");
cout << decision.origin_id()->canonical_form(idcf_no_version);
+
+ if (! decision.best())
+ cout << c::bold_yellow() << " (not the best version)" << c::normal();
+
cout << c::normal() << " " << decision.origin_id()->canonical_form(idcf_version) <<
" to " << decision.destination()->repository();