journalctl: hightlight log lines by priority

warn/notice = bright white
< error = red
This commit is contained in:
Lennart Poettering
2012-07-26 16:56:21 +02:00
parent 46b0d92225
commit 498261871d
4 changed files with 58 additions and 15 deletions
+6 -3
View File
@@ -2584,9 +2584,12 @@ static void print_status_info(UnitStatusInfo *i) {
}
if (i->id && arg_transport != TRANSPORT_SSH) {
int flags = (arg_lines*OUTPUT_SHOW_ALL |
arg_follow*OUTPUT_FOLLOW |
!arg_quiet*OUTPUT_WARN_CUTOFF);
int flags =
arg_lines * OUTPUT_SHOW_ALL |
arg_follow * OUTPUT_FOLLOW |
!arg_quiet * OUTPUT_WARN_CUTOFF |
on_tty() * OUTPUT_COLOR;
printf("\n");
show_journal_by_unit(i->id, arg_output, 0,
i->inactive_exit_timestamp_monotonic,