Search code examples
pythongettextpoeditpoxgettext

Generating a POT file


PoEdit causes problems because it scans also the Python sources in subdirectories where no scan is desired. So I want PoEdit to get new information about strings from a POT file. Here it is said that xgettext enables me to create a POT file from the sources. But I can't figure out how. It always generates a PO file.

How do I create a POT file with xgettext? Or is the old pygettext acceptable? Or is there another tool?


Solution

  • Just run xgettext and rename the resulting domainname.po file to domainname.pot.

    See http://www.gnu.org/software/gettext/manual/html_node/Template.html#Template