Am 2013-11-28 um 15:50 schrieb Henning Hraban Ramm <[email protected]>:
> > Am 2013-11-25 um 12:56 schrieb Henning Hraban Ramm <[email protected]>: > >> Hi again, >> >> since I edited a lot of files, e.g. used translation tags in .bft files and >> wrote my own *_templates.py, I need to update the .pot to update the .po >> files of my languages. >> I tried po/i18n_extract_from_wml_source.py with po/POTFILES (had to remove 4 >> nonexisting entries from that), but that reduced the list of translations to >> 36 valid and 4 invalid entries (please find it attached). >> >> What’s the right incantation? > > Now, this one is urgent, since I edited a lot of display code - how do I > get/update ALL the translatable strings? > („Unsubscribe meee“ was not a helpful answer…) > > I’ll try to understand gettext (again) and glue the general Python string > extraction result to the one from the above script, but I’m rather sure there > is a ready-made solution somewhere... Ok, finally understood that I just must make my own list of files (alias POTFILES). I do it now this way: #!/bin/bash BASE=~/workspace/invenio LIST=$BASE/POTFILES.txt POT=$BASE/po/uca.pot cd $BASE find modules -iname "*.bft" > $LIST find modules -iname "*.webdoc" >> $LIST python po/i18n_extract_from_wml_source.py . $LIST > $POT find modules -iname "*.py" > $LIST xgettext --files-from=$LIST --from-code=UTF-8 --join-existing --output=$POT rm $LIST … and then update my .po files from that .pot in POedit; seems to work… In the current .po files that I checked, there are a lot of strings for files that don’t exist (any more), e.g. modules/websubmit/web/publiline.py Greetlings, Hraban --- http://www.fiee.net https://www.cacert.org (I'm an assurer)

