From 9af571d26efc3b66a0e4743e33c54075a03bc3be Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Thu, 29 May 2025 09:29:17 +0300 Subject: also show last checked ago in stale report --- internal/state.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/internal/state.go b/internal/state.go index 062a698..cda360f 100644 --- a/internal/state.go +++ b/internal/state.go @@ -220,6 +220,12 @@ func (s state) reportBy(sb *strings.Builder, showStatusChange, isStaleReport boo sb.WriteString(name) sb.WriteString(": ") sb.WriteString(cs.output) + + if isStaleReport { + lastCheckedAgo := time.Since(time.Unix(cs.Epoch, 0)) + sb.WriteString(fmt.Sprintf(" (last checked %v ago)", lastCheckedAgo)) + } + sb.WriteString("\n") } -- cgit v1.2.3