开发者

xgettext extracts wrong literals

I use this to extract all string literals that need translation:

xgettext -o $@ -k"Localizer.get" $^ --from-code=utf-8

These should be extracted:

Localizer.get("Could not find the config file. (This should *not* happen!)")

These not:

SettingsWrapper.getString("date_format")

But both end up in m开发者_如何学运维y .pot file:

msgid "date_format"
msgstr ""

Is there some way to get this straight?


From the xgettext manual, getString is a default keyword specification for Java. You will need to disable default keywords and explicitly include any desired keyword specifications that were disabled which you want to enable. Try changing -k"Localizer.get" to -k -k"Localizer.get".

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜