| 359 | } |
| 360 | |
| 361 | command_result Core::runCommand(color_ostream& out, const std::string& command) |
| 362 | { |
| 363 | if (!command.empty()) |
| 364 | { |
| 365 | std::vector <std::string> parts; |
| 366 | Core::cheap_tokenise(command, parts); |
| 367 | if (parts.size() == 0) |
| 368 | return CR_NOT_IMPLEMENTED; |
| 369 | |
| 370 | std::string first = parts[0]; |
| 371 | parts.erase(parts.begin()); |
| 372 | |
| 373 | if (first[0] == '#') |
| 374 | return CR_OK; |
| 375 | |
| 376 | std::cerr << "Invoking: " << command << std::endl; |
| 377 | return runCommand(out, first, parts); |
| 378 | } |
| 379 | else |
| 380 | return CR_NOT_IMPLEMENTED; |
| 381 | } |
| 382 | |
| 383 | bool DFHack::is_builtin(color_ostream& con, const std::string& command) |
| 384 | { |
no test coverage detected