5

As the title states, I want to export the translations in code and deploy it with a version control system like GIT.

We have a multi-language Drupal system (English and German) and we have Localization Update module installed.

While some modules doesn't even have a German translations, some are insufficient and some translations are not how we like to have them.

So I add/edit the translations using the UI under admin/config/regional/translate/translate and I can export them into a de.po file under admin/config/regional/translate/export.

I don't know really where to put this file and commit/push so that I can update the languages on other development and production environments.

We have a 3 stage development environment. Local - Dev - Pro. I do all things in local and push to Dev.

But with translations I couldn't get this workflow. Everytime I update a string's translation, I do it on every environment manually and this is not a perfect way. There must be something I'm missing.

3

You could use Features Translations:

Features Translations adds a new Features component called Translations that allows to import/export sets of translated strings. String sets can be chosen per language and per text group.

2

Your best bet is to use the Potx Exportables module. Here is a quote about it (from the module's project page):

... aims to ease the deployment of translation .PO files that the great Potx module generates. No longer will you have to manually upload these files to keep your site translations up to date. You can manually batch import all PO files defined in custom modules or alternatively, you can use the always useful Drush command to make things easier for you.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.