Maintaining Translations on Your Repo#

How To Use Atlas#

atlas is a tool that pulls translations from the openedx-translations into your repository’s directory.

The recommended way to use atlas pull is to call the make pull_translations command in the repository which is described in details in the Enabling Translations on a New Repo document.

The atlas README has up to-date command line usage instructions. For example the following command pulls translations into the edx-platform repository:

cd /path/to/edx-platform
make pull_translations

The make pull_translations command will (roughly) run the following command:

atlas pull translations/edx-platform/conf/locale:conf/locale

Is It Working?#

To check if the translations pull command is working is to check the target directory conf/locale for the presence of the translations:

tree conf/locale  # or ls conf/locale
git status  # Should show the new files

Run your application and test translations by changing the user langauge from the Account Settings page.

What To Do If It’s Not Working?#

If the translations aren’t being pulled or not working as expected, here are some problems to check for:

Missing translations: Ensure the translations you’re looking to pull is available in the openedx-translations repository. Otherwise, an empty directory will be created. Use tree conf/locale to check if the translations are present.

.mo files are missing in Python applications: Ensure the translations are compiled to .po files after pulling the translations, because Python applications needs compiled .mo files.

Empty src/i18n/index.js in Micro-frontends: Ensure the src/i18n/index.js file is built after pulling the translations. Compile the i18n/index.js as seen the Makefile via intl-imports.js in the frontend-template-app to ensure the translations are available in the application.

Repo translations aren’t being pushed to transifex: Ensure the translations are enabled and pushed to and from Transifex as described in the Enabling Translations on a New Repo document.