Find / Detect / Format GetText strings used in files around
Actually there are two questions:
- is there a way to recursively pick up all GetText strings in current directory and all child dirs programmatically (using
exec
maybe or some)? - after i passed through the files within
xgettext
i got warning such as ... internationalized messages should not contain the `\r
So how to force xgettext to delete \n, \r, \t etc. automatically when string is found to avoid mentioned error so .PO file would be friendly formatted?
Thanks for c开发者_StackOverflow社区oming links and advices :)
Closed. Only way i see - invoke xgettext from PHP as :
passthru('xgettext -n *.php', $result);
With params :
- http://www.php.net/manual/en/function.passthru.php
- How to create .po files using xgettext on Windows?
- http://www.gnu.org/s/hello/manual/gettext/xgettext-Invocation.html
精彩评论