| 157 | |
| 158 | |
| 159 | void Commands::ShellCompletion::list_commands() |
| 160 | { |
| 161 | bool first = true; |
| 162 | for (auto &cmd : commands->GetAllCommandObjects()) |
| 163 | { |
| 164 | if (cmd->GetCommand() == GetCommand()) |
| 165 | { |
| 166 | // Skip myself |
| 167 | continue; |
| 168 | } |
| 169 | if (!first) |
| 170 | { |
| 171 | std::cout << " "; |
| 172 | } |
| 173 | first = false; |
| 174 | std::cout << cmd->GetCommand(); |
| 175 | } |
| 176 | std::cout << std::endl; |
| 177 | } |
| 178 | |
| 179 | |
| 180 | /** |
nothing calls this directly
no test coverage detected