From 55b706a8a61d5f0b8b529613edae50e67ecf4889 Mon Sep 17 00:00:00 2001 From: Sergey Matveev Date: Fri, 26 Aug 2022 18:15:15 +0300 Subject: [PATCH] Missing NO_COLOR check --- doc/news.texi | 8 ++++++++ log.go | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/doc/news.texi b/doc/news.texi index 856e186..6b7d22d 100644 --- a/doc/news.texi +++ b/doc/news.texi @@ -2,6 +2,14 @@ @cindex news @unnumbered News +@anchor{Release 1_26_0} +@section Release 1.26.0 +@itemize +@item + Debug output contained colour-related attribute even if + @env{$NO_COLOR=1} was set. +@end itemize + @anchor{Release 1_25_0} @section Release 1.25.0 @itemize diff --git a/log.go b/log.go index bb286ed..2a3d805 100644 --- a/log.go +++ b/log.go @@ -102,7 +102,7 @@ func init() { } func erasedStatus(s, end string) string { - if NoProgress { + if NoProgress || NoColor { return s + end } return s + KeyEraseLine + end -- 2.44.0