Yaakov Selkowitz 040ce1
From 35739c2a2298e61caacb45157706bf342ffcd20e Mon Sep 17 00:00:00 2001
Yaakov Selkowitz 040ce1
From: Florian Festi <ffesti@redhat.com>
Yaakov Selkowitz 040ce1
Date: Tue, 27 Apr 2021 10:09:41 +0200
Yaakov Selkowitz 040ce1
Subject: [PATCH] find-lang.sh: Support long languages names for QT
Yaakov Selkowitz 040ce1
Yaakov Selkowitz 040ce1
Most language abbreviations are just two characters but some are longer.
Yaakov Selkowitz 040ce1
Allow an arbiraty number of character instead of exactly two in the names
Yaakov Selkowitz 040ce1
of .qm files (QT translations). This brings the handling of .qm files in
Yaakov Selkowitz 040ce1
line with all other file types.
Yaakov Selkowitz 040ce1
Yaakov Selkowitz 040ce1
Resolves: #1642
Yaakov Selkowitz 040ce1
---
Yaakov Selkowitz 040ce1
 scripts/find-lang.sh | 14 +++++++-------
Yaakov Selkowitz 040ce1
 1 file changed, 7 insertions(+), 7 deletions(-)
Yaakov Selkowitz 040ce1
Yaakov Selkowitz 040ce1
diff --git a/scripts/find-lang.sh b/scripts/find-lang.sh
Yaakov Selkowitz 040ce1
index f2aa7d8951..b97210b117 100755
Yaakov Selkowitz 040ce1
--- a/scripts/find-lang.sh
Yaakov Selkowitz 040ce1
+++ b/scripts/find-lang.sh
Yaakov Selkowitz 040ce1
@@ -249,13 +249,13 @@ s:%lang(C) ::
Yaakov Selkowitz 040ce1
 
Yaakov Selkowitz 040ce1
 find "$TOP_DIR" -type f -o -type l|sed '
Yaakov Selkowitz 040ce1
 s:'"$TOP_DIR"'::
Yaakov Selkowitz 040ce1
-'"$NO_ALL_NAME$QT"'s:\(.*/'"$NAME"'_\([a-zA-Z]\{2\}\([_@].*\)\?\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
-'"$ALL_NAME$QT"'s:^\([^%].*/\([a-zA-Z]\{2\}[_@].*\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
-'"$ALL_NAME$QT"'s:^\([^%].*/\([a-zA-Z]\{2\}\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
-'"$ALL_NAME$QT"'s:^\([^%].*/[^/_]\+_\([a-zA-Z]\{2\}[_@].*\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
-'"$ALL_NAME$QT"'s:^\([^%].*/[^/_]\+_\([a-zA-Z]\{2\}\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
-'"$ALL_NAME$QT"'s:^\([^%].*/[^/]\+_\([a-zA-Z]\{2\}[_@].*\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
-'"$ALL_NAME$QT"'s:^\([^%].*/[^/]\+_\([a-zA-Z]\{2\}\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
+'"$NO_ALL_NAME$QT"'s:\(.*/'"$NAME"'_\([a-zA-Z]\+\([_@].*\)\?\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
+'"$ALL_NAME$QT"'s:^\([^%].*/\([a-zA-Z]\+[_@].*\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
+'"$ALL_NAME$QT"'s:^\([^%].*/\([a-zA-Z]\+\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
+'"$ALL_NAME$QT"'s:^\([^%].*/[^/_]\+_\([a-zA-Z]\+[_@].*\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
+'"$ALL_NAME$QT"'s:^\([^%].*/[^/_]\+_\([a-zA-Z]\+\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
+'"$ALL_NAME$QT"'s:^\([^%].*/[^/]\+_\([a-zA-Z]\+[_@].*\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
+'"$ALL_NAME$QT"'s:^\([^%].*/[^/]\+_\([a-zA-Z]\+\)\.qm$\):%lang(\2) \1:
Yaakov Selkowitz 040ce1
 s:^[^%].*::
Yaakov Selkowitz 040ce1
 s:%lang(C) ::
Yaakov Selkowitz 040ce1
 /^$/d' >> $MO_NAME