Search code examples
pythondjangodjango-i18n

django-admin.py makemessages does not create .po files


Here I've marked strings for translation, base.html:

  <li><a href="{% url 'specific_static_page' 'apie-mus' %}">{% trans 'Apie mus' %}</a></li>
  <li><a href="{% url 'categories_index' %}">{% trans 'Produktai' %}</a></li>
  <li><a href="{% url 'news_index' %}">{% trans 'Naujienos' %}</a></li>
  <li><a href="{% url 'specific_static_page' 'dokumentai' %}">{% trans 'Dokumentai' %}</a></li>
  <li><a href="{% url 'specific_static_page' 'kontaktai' %}">{% trans 'Kontaktai' %}</a></li>

settings.py:

LOCALE_PATHS = (
    'C:/Users/Marijus/PycharmProjects/legatine/locale',
)

and I run the command :

django-admin.py makemessages -a 

It runs without errors or anything, however it doesn't create any .po files. What am I doing wrong here ?


Solution

  • That command is used to reexamine all the source but to create the po files you must specify the language with

    django-admin.py makemessages -l de
    

    Being de the language Deutsche