
Untitled
By: a guest on
Jun 1st, 2012 | syntax:
None | size: 0.80 KB | hits: 18 | expires: Never
How to properly add entries for computed values to the django internationalization messages file?
{% trans var %}
msgid "Alice"
msgstr "Alicja"
#~ msgid "Alice"
#~ msgstr "Alicja"
from django.utils.translation import ugettext_lazy as _, pgettext
def dummy_for_makemessages():
"""
This function allows manage makemessages to find the forecast types for translation.
Removing this code causes makemessages to comment out those PO entries, so don't do that
unless you find a better way to do this
"""
pgettext('forecast type', 'some string')
pgettext('forecast type', 'some other string')
pgettext('forecast type', 'yet another string')
pgettext('forecast type', 'etc')
pgettext('forecast type', 'etc again')
pgettext('forecast type', 'and again and again')