Pulling Translations From Transifex¶
First make sure you have the Transifex command-line client installed:
$ pip install transifex-client
Then use the
pull command to pull translations:
$ tx pull
To create locale directories for newly created translations you will need to call
tx pull with the
Compiling Message Catalogs¶
This is required for Django to see the translations.
$ python manage.py compilemessages
On Windows, you will need to install GNU’s gettext command. To do that you need to install gettext-iconv. During the installation, make sure to check “Add to PATH”.
Don’t forget to restart your terminal or software after the installation to take the changes into effect.
Extracting Messages to Translate¶
This will update the English language files with messages that appear in your code.
For the backend code and templates:
$ python manage.py makemessages -l en --extension=email,html,mjml,py,txt --ignore="templates/templated_email/compiled/*"
$ python manage.py makemessages -l en -d djangojs --ignore="_build/*" --ignore="node_modules/*" --ignore="saleor/static/assets/*"