As part of Translation project, Public Lab, we invite contributors to translate various parts of the Forum so that we can make Publiclab.org more genial and accessible to new and existing users and foster diversity. The Public Lab website is available in different languages, with translation provided by community members. As the website menus, buttons, and other interfaces change, those new texts must be imported back into the translation system to be shown to translators. This activity shows how that process works; it can be done by Transifex managers only.
Importing new strings and translations from Github to the Transifex project is automated and syncs files at regular intervals. These options are not available to language translators.
The only checks necessary are:
- YAML config file in Project integration
In Project settings, we have an integration tab. In this, we have 2 integration options; we are currently using the integration with the Github option. On the top right of this section, we can find an edit settings option.
This is the config file for the Translation Project. On adding any new language to the Github repository if it does not follow the language code used by transifex, we need to add it to the language mapping list in the format .
remote-language-code : local-file-name. You can read about other options here
- Auto-update link for source file
This is the link that the Transifex bot uses to sync source files. The link needs to be in
raw form of Github file link. In case the source file changes, we need to update this link.
Exporting translated strings from Transifex Project
Manually download translation files
We can download the translation manually by the option available to download.
The language file can then be replaced with an updated file by raising a PR on the
main branch of
Sync translation files
The files can be directly synced using
Send to Github option in the integration tab of Project Settings. This syncs the source and translation files. If the language is 100% reviewed then a PR is raised to merge the translated strings. You can change the threshold if you want to import new translations but this might lead to adding some empty strings for missing translations.
Transifex also automatically raises a PR when a language is 100% translated.