Running msgmerge with two PO files



When we used l10n-status.gnome.org and PO files were much easier to
get then POT files, I tried "msgmerge local-po-file
remote-msgmerged-po-file" with an odd behaviour (describe below). This
e-mail is to let you guys know that starting with the next gettext
version, we'll be able to do that safely.

Leonardo Fontenelle

---------- Forwarded message ----------
From: Bruno Haible <bruno clisp org>
Date: 08/01/2007 15:10
Subject: Re: Feature request for gettext
To: Leonardo Fontenelle <leo fontenelle gmail com>
Cc: bug-gnu-gettext gnu org


Leonardo Fontenelle wrote on 2006-11-12:
Currently msgmerge works fine if the "ref.pot" parameter is a POT
file, but if it is a PO file the result is an updated PO file were old
translations are uncommented, which is very disturbing.

Making msgmerge effectively accept a PO file as "ref.pot" would let
GNOME translators update their local PO files from the updated ones in
http://l10n-status.gnome.org.

Thank you for reporting this. This will be implemented in the next gettext
release (0.16.2), through this patch.

Bruno


*** gettext-tools/src/msgmerge.c        2006-12-03 01:25:49.000000000 +0100
--- gettext-tools/src/msgmerge.c        2007-01-07 21:17:26.000000000 +0100
***************
*** 1073,1078 ****
--- 1073,1084 ----
       result->prev_msgid_plural = prev_msgid_plural;
     }

+   /* If the reference message was obsolete, make the resulting message
+      obsolete.  This case doesn't occur for POT files, but users sometimes
+      use PO files that are themselves the result of msgmerge instead of POT
+      files.  */
+   result->obsolete = ref->obsolete;
+
   /* Take the file position comments from the reference file, as they
      are generated by xgettext.  Any in the definition file are old ones
      collected by previous runs of xgettext and msgmerge.  */


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]