Kaydet (Commit) e8fab3e4 authored tarafından Christian Lohmaier's avatar Christian Lohmaier

pot creation: don't ignore multiple locations/occurrences…

when making paths relative to SRCDIR
674b1c92 as well as the code before
ignored multiple locations in po file

Change-Id: Idf5c5ca99d0ec8272e669621e132d7a495ceaff8
Reviewed-on: https://gerrit.libreoffice.org/50439Reviewed-by: 's avatarChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>
Tested-by: 's avatarChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>
üst 35fc4527
......@@ -29,7 +29,6 @@ with open(ofile, "a") as output:
for entry in po:
keyid = entry.msgctxt + '|' + entry.msgid
print >> output, '#. ' + polib.genKeyId(keyid)
location = entry.occurrences[0][0]
location = os.path.relpath(location, os.environ['SRCDIR'])
entry.occurrences[0] = location, entry.occurrences[0][1]
for i, occurrence in enumerate(entry.occurrences):
entry.occurrences[i] = os.path.relpath(occurrence[0], os.environ['SRCDIR']), occurrence[1]
print >> output, entry
......@@ -29,7 +29,6 @@ with open(ofile, "a") as output:
for entry in po:
keyid = entry.msgctxt + '|' + entry.msgid
print >> output, '#. ' + polib.genKeyId(keyid)
location = entry.occurrences[0][0]
location = os.path.relpath(location, os.environ['SRCDIR'])
entry.occurrences[0] = location, entry.occurrences[0][1]
for i, occurrence in enumerate(entry.occurrences):
entry.occurrences[i] = os.path.relpath(occurrence[0], os.environ['SRCDIR']), occurrence[1]
print >> output, entry
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment