From c12db93703849ee7294d716e1a1d645bb2763a3c Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Sat, 26 Jul 2014 06:27:43 +0200 Subject: [PATCH] Do not add obsolete translation entries msgmerge keeps obsolete translation entries but we should filter them out. Do the filtering with msgattrib. Note this is only needed for log files, the other files are handled correctly since update_catalog has an option for this. This fixes the issue seen in glance: https://review.openstack.org/#/c/105069/ Change-Id: I956e4af59d7bbd6e90583bdb9412c9bf85b87019 --- .../files/slave_scripts/propose_translation_update.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/modules/openstack_project/files/slave_scripts/propose_translation_update.sh b/modules/openstack_project/files/slave_scripts/propose_translation_update.sh index 1c33c54712..b85fbd23ef 100755 --- a/modules/openstack_project/files/slave_scripts/propose_translation_update.sh +++ b/modules/openstack_project/files/slave_scripts/propose_translation_update.sh @@ -51,6 +51,10 @@ for level in $LEVELS ; do msgmerge --update --no-fuzzy-matching $f \ --backup=none \ ${PROJECT}/locale/${PROJECT}-log-${level}.pot + # Remove obsolete entries + msgattrib --no-obsolete --force-po \ + --output-file=${f}.tmp ${f} + mv ${f}.tmp ${f} done fi done