This repository has been archived by the owner on Nov 2, 2020. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 272
Extraction of context information for I18n #75
Comments
In the meantime I implemented a complete native string extractor which uses the Twig lexer and parser. I also took the opportunity to extend the gettext support to use the system more fully (domains, categories, contexts, plurals, string formatting). The only thing missing is a decent library for writing the extracted strings to a PO file. Does anyone happen to know one? Otherwise I'll have to write one too. Once that's done and it's brushed up a bit I'll attach the code here... |
I did not, but this is still rather limited for my needs. A single |
Closed
Issue superseded by #76. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The way the
gettext
function is supported using thetrans
tag is too limited. Specifically:Compiling the templates and running
xgettext
against them adds meaningless file names and line numbers to the extracted strings, which do not help at all.There's no way to add translator comments to the extracted strings, like:
xgettext
is able to extract those, but there's no way to embed such comments when compiling a Twig template.For complex projects with distributed translators, both these features are rather important. I'm afraid a native extractor that can parse Twig templates is necessary for this.
The text was updated successfully, but these errors were encountered: