From 711e444e8e411c302aed407b7d011e0652cdf223 Mon Sep 17 00:00:00 2001 From: JustAnotherArchivist Date: Sun, 2 Feb 2020 05:28:17 +0000 Subject: [PATCH] Highlight jobs that have been inactive for over 6 hours --- archivebot-jobs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/archivebot-jobs b/archivebot-jobs index fb54242..0ed0e5f 100755 --- a/archivebot-jobs +++ b/archivebot-jobs @@ -123,7 +123,7 @@ if True: # For sensible indentation def coloured_time_ago(diff): if diff >= 300: - return "\x1b[0;31m" + time_ago(diff) + "\x1b[0m" + return f"\x1b[{0 if diff < 6 * 3600 else 7};31m" + time_ago(diff) + "\x1b[0m" else: return time_ago(diff)