Kaydet (Commit) 674b1c92 authored tarafından Gabor Kelemen's avatar Gabor Kelemen Kaydeden (comit) Andras Timar

Save full file path to pot files

As requested here:
http://nabble.documentfoundation.org/libreoffice-l10n-Pootle-source-file-paths-not-available-anymore-td4229127.html

This adds the full source file path in case of .hrc and .ui files
to the generated pot, relatie to srcdir. So instead of
personalization.hrc:31
we can have
cui/inc/personalization.hrc:31
for better context for translators.
Since this is only in comment this will not change the translated
status of strings.
TODO: the other file formats we use are not affected by this.

Change-Id: Id436d66698c93e07c46bf9c20601c5b480eadd0b
Reviewed-on: https://gerrit.libreoffice.org/46591Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarAndras Timar <andras.timar@collabora.com>
üst e16668e1
......@@ -30,6 +30,6 @@ with open(ofile, "a") as output:
keyid = entry.msgctxt + '|' + entry.msgid
print >> output, '#. ' + polib.genKeyId(keyid)
location = entry.occurrences[0][0]
location = os.path.basename(location)
location = os.path.relpath(location, os.environ['SRCDIR'])
entry.occurrences[0] = location, entry.occurrences[0][1]
print >> output, entry
......@@ -30,6 +30,6 @@ with open(ofile, "a") as output:
keyid = entry.msgctxt + '|' + entry.msgid
print >> output, '#. ' + polib.genKeyId(keyid)
location = entry.occurrences[0][0]
location = os.path.basename(location)
location = os.path.relpath(location, os.environ['SRCDIR'])
entry.occurrences[0] = location, entry.occurrences[0][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