| 379 | } |
| 380 | |
| 381 | MetadataResult SetOutputMode(ShellState &state, const vector<string> &args) { |
| 382 | if (args.size() > 3) { |
| 383 | return MetadataResult::PRINT_USAGE; |
| 384 | } |
| 385 | if (args.size() == 1) { |
| 386 | state.PrintF("current output mode: %s\n", ShellState::ModeToString(state.mode)); |
| 387 | } else { |
| 388 | if (!state.SetOutputMode(args[1], args.size() > 2 ? args[2].c_str() : nullptr)) { |
| 389 | return MetadataResult::FAIL; |
| 390 | } |
| 391 | } |
| 392 | return MetadataResult::SUCCESS; |
| 393 | } |
| 394 | |
| 395 | MetadataResult QuitProcess(ShellState &, const vector<string> &args) { |
| 396 | return MetadataResult::EXIT; |
nothing calls this directly
no test coverage detected