How do I get makemessages to ignore already-translated strings?
In Django 5, I am running
./manage.py makemessages -l fr
I have also copied templates/registration/registration_form.html
from the “registration” app (django-registration-redux), so that I can modify it to extend the base.html from my project.
Now, every translated string in my copy of registration_form.html
is making its way into my locale/fr/LC_MESSAGES/django.po
file for translation.
However, those strings are already translated in the app directory. The docs says:
[Django] looks for and uses if it exists a locale directory in each of the installed apps listed in INSTALLED_APPS
That is a correct and fine behavior. The translations are fine.
So, I don’t want all those strings in my file, looking like they need to be translated again.
I tried each of the following:
./manage.py makemessages -l fr -i registration/locale
./manage.py makemessages -l fr -i .venv/lib/python3.11/site-packages/registration/locale/
to no effect.