From b010a855f6a08800ed74b8975077c8e3755f0561 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hozza?= Date: Tue, 18 Mar 2025 13:26:31 +0100 Subject: [PATCH] test/shared_lib.sh: make *print functions print to stderr MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This will allow using them inside Bash function that return values, without tainting the returned value. Signed-off-by: Tomáš Hozza --- test/cases/shared_lib.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/cases/shared_lib.sh b/test/cases/shared_lib.sh index 1256c553d..197c0af53 100755 --- a/test/cases/shared_lib.sh +++ b/test/cases/shared_lib.sh @@ -35,13 +35,13 @@ function get_build_info() { # Colorful timestamped output. function greenprint { - echo -e "\033[1;32m[$(date -Isecond)] ${1}\033[0m" + echo -e "\033[1;32m[$(date -Isecond)] ${1}\033[0m" >&2 } function yellowprint { - echo -e "\033[1;33m[$(date -Isecond)] ${1}\033[0m" + echo -e "\033[1;33m[$(date -Isecond)] ${1}\033[0m" >&2 } function redprint { - echo -e "\033[1;31m[$(date -Isecond)] ${1}\033[0m" + echo -e "\033[1;31m[$(date -Isecond)] ${1}\033[0m" >&2 }