From d354f0b107c0d54e5f9d2ec39c7f600909807e94 Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Thu, 22 Jul 2021 16:31:43 +0200 Subject: [PATCH] build: i18n-sync.sh: fix i18n-update.pl invocation Fixes: 4d3c0f347c ("build: i18n-sync.sh: allow restricting to directory") Signed-off-by: Jo-Philipp Wich --- build/i18n-sync.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/build/i18n-sync.sh b/build/i18n-sync.sh index ada3f3cb48..9a3060a42d 100755 --- a/build/i18n-sync.sh +++ b/build/i18n-sync.sh @@ -15,4 +15,10 @@ find "${1:-.}" -name '*.pot' -and -not -name base.pot | \ echo "done" done -./build/i18n-update.pl "${1:-./*/*/po}" +if [ -n "$1" ]; then + find "$1" -path '*/templates/*.pot' -printf '%h ' | \ + xargs -r -n 1 dirname | \ + xargs -r -n 1 ./build/i18n-update.pl +else + ./build/i18n-update.pl +fi