About Solving Conflicts in django.po Files

When you have git conflicts in django.po files, probably the best way to solve them is to save the conflicting versions as django-older.po and django-newer.po temporarily and use msgcat command to combine them:

1
2
3
4
$ mv django.po django-newer.po
$ git pull
$ mv django.po django-older.po
$ msgcat --use-first django-newer.po django-older.po > django.po

Then rerun the makemessages and compilemessages management commands.

Tips and Tricks Programming Development Django 5.x Django 4.2 Django 3.2 Git gettext