bug-gnu-utils
[Top][All Lists]
Advanced

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

Running xgettext on diff/patch files


From: Cristian Rigamonti
Subject: Running xgettext on diff/patch files
Date: Sun, 15 Nov 2009 21:16:04 +0100
User-agent: Mutt/1.5.18 (2008-05-17)

Hi, I'd like to run xgettext on some patches containing PHP code, to create a
.pot file containing only strings contained in the patches, instead of all
strings contained in the patched files.

However, xgettext silently ignores the diff/patch input file, creating an empty
output file. Renaming the input file with a .php extension doesn't help. It
seems that xgettext actually checks the syntax of the input file and refuses to
work on diff/patch files. Is this an intended behaviour or a bug?

So far, the only way I found is to trick xgettext appending a bogus "<?php" line
to the beginning of the patch, and removing any "?>" in it; but I guess if
there is a more orthodox way to do it...

Cri

-- 
GPG/PGP Key-Id 0x943A5F0E      -    http://www.linux.it/~cri/cri.asc

Attachment: signature.asc
Description: Digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]