Skip to content
This repository has been archived by the owner on Mar 6, 2018. It is now read-only.

Latest commit

 

History

History
22 lines (11 loc) · 440 Bytes

babel_info.md

File metadata and controls

22 lines (11 loc) · 440 Bytes

Translating with babel

create pot file:

pybabel extract -F babel.cfg -o messages.pot .

add language and create po file:

pybabel init -i messages.pot -d translations -l de

translate file under translations/de/LC_MESSAGES/messages.po

compile:

pybabel compile -d translations

If strings change, create new pot file and merge changes:

pybabel update -i messages.pot -d translations

https://pythonhosted.org/Flask-Babel/