mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 05:18:12 +00:00
HackStudio: Use new format functions.
This commit is contained in:
parent
3b601cd4bd
commit
7c4fb2b804
23 changed files with 112 additions and 117 deletions
|
@ -76,11 +76,11 @@ void TerminalWrapper::run_command(const String& command)
|
|||
ASSERT_NOT_REACHED();
|
||||
}
|
||||
if (WIFEXITED(wstatus)) {
|
||||
m_terminal_widget->inject_string(String::format("\033[%d;1m(Command exited with code %d)\033[0m\n", wstatus == 0 ? 32 : 31, WEXITSTATUS(wstatus)));
|
||||
m_terminal_widget->inject_string(String::formatted("\033[{};1m(Command exited with code {})\033[0m\n", wstatus == 0 ? 32 : 31, WEXITSTATUS(wstatus)));
|
||||
} else if (WIFSTOPPED(wstatus)) {
|
||||
m_terminal_widget->inject_string(String::format("\033[34;1m(Command stopped!)\033[0m\n"));
|
||||
m_terminal_widget->inject_string("\033[34;1m(Command stopped!)\033[0m\n");
|
||||
} else if (WIFSIGNALED(wstatus)) {
|
||||
m_terminal_widget->inject_string(String::format("\033[34;1m(Command signaled with %s!)\033[0m\n", strsignal(WTERMSIG(wstatus))));
|
||||
m_terminal_widget->inject_string(String::formatted("\033[34;1m(Command signaled with {}!)\033[0m\n", strsignal(WTERMSIG(wstatus))));
|
||||
}
|
||||
m_process_state_widget->set_tty_fd(-1);
|
||||
m_pid = -1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue