blivet-gui/0001-Ignore-fallback-ITS-rule-warning-from-gettext.patch

29 lines
997 B
Diff

From 0aae60b135c0f15cbbdb8b196cb3a43e1308d840 Mon Sep 17 00:00:00 2001
From: Vojtech Trefny <vtrefny@redhat.com>
Date: Sat, 8 Aug 2020 21:42:20 +0200
Subject: [PATCH] Ignore fallback ITS rule warning from gettext
New gettext 0.21 started warning about this and translation canary
treats all warning as errors. But this one is really just a warning
we don't care about.
---
translation-canary/xgettext_werror.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/translation-canary/xgettext_werror.sh b/translation-canary/xgettext_werror.sh
index 36eefec..5fb32a8 100755
--- a/translation-canary/xgettext_werror.sh
+++ b/translation-canary/xgettext_werror.sh
@@ -37,7 +37,7 @@ returncode=0
xgettext_output="$(LC_MESSAGES=C xgettext "$@" 2>&1)" || returncode=$?
# Look for warnings
-if echo "$xgettext_output" | fgrep -q "warning: "; then
+if echo "$xgettext_output" | awk '/warning: / && !/fallback ITS rule/{rc=1}; END {exit !rc}'; then
returncode=1
fi
--
1.8.3.1