aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2010-06-06 15:59:03 +0100
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2010-06-06 17:21:25 +0100
commit2dfb95e9055f66ac5f76547601ff404744d3a330 (patch)
tree3b7b12806e68de59e4d006a155b56d4e4b5cb0ee
parentcc7a319cdebc82fbca85ed9c954774e6def4da0f (diff)
downloadpaludis-2dfb95e9055f66ac5f76547601ff404744d3a330.tar.gz
paludis-2dfb95e9055f66ac5f76547601ff404744d3a330.tar.xz
Show no slots less uglily
-rw-r--r--src/clients/cave/cmd_show.cc5
-rw-r--r--src/clients/cave/formats.cc6
-rw-r--r--src/clients/cave/formats.hh1
3 files changed, 11 insertions, 1 deletions
diff --git a/src/clients/cave/cmd_show.cc b/src/clients/cave/cmd_show.cc
index 5d22f0b..38ad665 100644
--- a/src/clients/cave/cmd_show.cc
+++ b/src/clients/cave/cmd_show.cc
@@ -882,7 +882,10 @@ namespace
cout << format_general_s(f::show_package_best(), "");
}
- cout << format_general_s(f::show_package_slot(), slot_name);
+ if (slot_name.empty())
+ cout << format_general_s(f::show_package_no_slot(), slot_name);
+ else
+ cout << format_general_s(f::show_package_slot(), slot_name);
cout << endl;
}
diff --git a/src/clients/cave/formats.cc b/src/clients/cave/formats.cc
index 1984900..bbc55d4 100644
--- a/src/clients/cave/formats.cc
+++ b/src/clients/cave/formats.cc
@@ -268,6 +268,12 @@ paludis::cave::f::show_package_slot()
}
const std::string
+paludis::cave::f::show_package_no_slot()
+{
+ return " {no slot}";
+}
+
+const std::string
paludis::cave::f::show_package_id_heading()
{
return " " + c::bold_blue_or_pink() + "%s" + c::normal() + "\\n";
diff --git a/src/clients/cave/formats.hh b/src/clients/cave/formats.hh
index 60bb395..646f063 100644
--- a/src/clients/cave/formats.hh
+++ b/src/clients/cave/formats.hh
@@ -70,6 +70,7 @@ namespace paludis
const std::string show_package_version_unavailable();
const std::string show_package_best();
const std::string show_package_slot();
+ const std::string show_package_no_slot();
const std::string show_package_id_heading();
const std::string show_package_id_masks();