Update picard.pot

This commit is contained in:
Lukáš Lalinský
2012-05-29 08:46:57 +02:00
parent 8c170eff0e
commit ea024278e5
2 changed files with 4243 additions and 4225 deletions

File diff suppressed because it is too large Load Diff

31
po/update-pot.py Executable file
View File

@@ -0,0 +1,31 @@
#!/usr/bin/env python
import glob
import os.path
import shutil
sources = []
for root, dirs, files in os.walk(os.path.join('..', 'picard')):
for name in files:
if name.endswith('.py'):
sources.append(os.path.join(root, name))
cmd = "xgettext --copyright-holder=MusicBrainz " \
"--msgid-bugs-address=http://tickets.musicbrainz.org/ " \
"--add-comments=TR -L Python -d picard -o picard.pot --keyword=N_ " + \
" ".join(sources)
print cmd
os.system(cmd)
print
f = file('picard.pot', 'rt')
lines = f.readlines()
f.close()
f = file('picard.pot', 'wt')
for line in lines:
if line.startswith('#. TR: '):
line = '#. ' + line[7:]
f.write(line)
f.close()