X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=Scheduler%2FConsole%2FExecutor.cc;h=8f054c789c70885b7cc01fb76220189235cfbc2d;hb=c77d350c7bb263316c35f535542cdeaec3d2aab6;hp=80d632fb504a0c548045b9fff08003ba72e28c3b;hpb=2da517bbcdb2af10d2322fc762ca27774b53b435;p=senf.git diff --git a/Scheduler/Console/Executor.cc b/Scheduler/Console/Executor.cc index 80d632f..8f054c7 100644 --- a/Scheduler/Console/Executor.cc +++ b/Scheduler/Console/Executor.cc @@ -33,6 +33,7 @@ #include "../../Utils/senfassert.hh" #include "../../Utils/Range.hh" #include "../../Utils/String.hh" +#include "../../Utils/range.hh" //#include "Executor.mpp" #define prefix_ @@ -232,7 +233,7 @@ prefix_ void senf::console::Executor::help(std::ostream & output, ParseCommandInfo::TokensRange path) { GenericNode const & node (traverseNode(path)); - output << prettyName(typeid(node)) << " at " << node.path() << "\n\n"; + // output << prettyName(typeid(node)) << " at " << node.path() << "\n\n"; node.help(output); output << std::flush; } @@ -301,7 +302,7 @@ prefix_ std::string senf::console::Executor::complete(DirectoryNode & dir, { if (! dir.hasChild(name)) { DirectoryNode::ChildrenRange completions (dir.completions(name)); - if (completions.size() == 1) + if (has_one_elt(completions)) return completions.begin()->first; } return name;