[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-i18n-doc
Subject: Re: Review Request 7106: AppStream support for l10n-script (example)
From: Burkhard_Lück <lueck () hube-lueck ! de>
Date: 2014-04-30 6:20:37
Message-ID: 20140430062037.9431.3332 () probe ! kde ! org
[Download RAW message or body]
> On April 29, 2014, 11:38 p.m., Matthias Klumpp wrote:
> > Okay :-)
> > I also found another issue (script filename was wrong) and committed the result.
> > How can I test the script, by the way? And if it explodes, do I get some debug \
> > data and does this harm the translation process? Also, does the l10n-server have \
> > a recent-enough version of itstool now? Cheers,
> > Matthias
Scripty's log see ftp://l10n.kde.org/140430.trunk_l10n-kde4
No error message, but Scripty created four empty pot files due to a wrong tmp file \
name, fixed already
Today only creating of four empty foo.appdata.pot happened, no merging from po files \
into foo.appdata.xml because we have no translations so far.
- Burkhard
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://svn.reviewboard.kde.org/r/7106/#review11104
-----------------------------------------------------------
On April 29, 2014, 4:31 p.m., Matthias Klumpp wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://svn.reviewboard.kde.org/r/7106/
> -----------------------------------------------------------
>
> (Updated April 29, 2014, 4:31 p.m.)
>
>
> Review request for Localization and Translation (l10n) and Albert Astals Cid.
>
>
> Repository: kde
>
>
> Description
> -------
>
> Hi!
> It's very difficult to extend the l10n-script if you don't know it's internal \
> workings, and if all comments are stripped out, so in order to get AppStream \
> support into the l10n-script, I created two small bash scripts to translate \
> AppStream upstream metadata:
> extract_metainfo.sh: This script generates .pot files from metadata
> XML files found in a project. Just cd to the directory you want the
> resulting pot files to be stored in, then call the script and point it
> at the project's source tree you want to be searched for the XML
> files.
>
> merge_metainfo.sh: The script merges translation back into the XML
> files. Simply cd to a directory which stores .mo files with the
> translated data and call the script with the project's source dir as
> first parameter.
>
> These scripts illustrate how translation of the XML can be done in
> KDE. I would kindly ask the l10n-script developers to take a look at
> it any maybe integrate it at the proper places, because they know the
> code way better than I do.
> The scripts can also be found at:
> http://people.freedesktop.org/~mak/appstream/kde-asmetadata-l10n.tar.gz
> (I also included a demo XML file there)
>
> If you have questions, please let me know!
> Cheers,
> Matthias
>
>
> Diffs
> -----
>
> trunk/l10n-kde4/scripts/extract_metainfo.sh PRE-CREATION
> trunk/l10n-kde4/scripts/as-metainfo.its PRE-CREATION
> trunk/l10n-kde4/scripts/update_translations 1384853
>
> Diff: https://svn.reviewboard.kde.org/r/7106/diff/
>
>
> Testing
> -------
>
> * Finds AppStream metadata in project source directories
> * .pot extraction works
> * Merging translation to untranslated files works
> * Merging new translation into already translated metadata files works (without \
> duplicating entries)
> * Resulting files are valid AppStream metadata files (compliance-check passed)
>
>
> Thanks,
>
> Matthias Klumpp
>
>
[Attachment #3 (text/html)]
<html>
<body>
<div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
<table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 \
solid;"> <tr>
<td>
This is an automatically generated e-mail. To reply, visit:
<a href="https://svn.reviewboard.kde.org/r/7106/">https://svn.reviewboard.kde.org/r/7106/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;"> <p style="margin-top: 0;">On April 29th, 2014, 11:38 p.m. UTC, <b>Matthias \
Klumpp</b> wrote:</p> <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;"> <pre style="white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Okay :-) I also found another issue (script filename was wrong) and \
committed the result. How can I test the script, by the way? And if it explodes, do I \
get some debug data and does this harm the translation process? Also, does the \
l10n-server have a recent-enough version of itstool now? Cheers,
Matthias</pre>
</blockquote>
</blockquote>
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Scripty's log see \
ftp://l10n.kde.org/140430.trunk_l10n-kde4
No error message, but Scripty created four empty pot files due to a wrong tmp file \
name, fixed already
Today only creating of four empty foo.appdata.pot happened, no merging from po files \
into foo.appdata.xml because we have no translations so far.</pre> <br />
<p>- Burkhard</p>
<br />
<p>On April 29th, 2014, 4:31 p.m. UTC, Matthias Klumpp wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('https://svn.reviewboard.kde.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); \
background-position: left top; background-repeat: repeat-x; border: 1px black \
solid;"> <tr>
<td>
<div>Review request for Localization and Translation (l10n) and Albert Astals \
Cid.</div> <div>By Matthias Klumpp.</div>
<p style="color: grey;"><i>Updated April 29, 2014, 4:31 p.m.</i></p>
<div style="margin-top: 1.5em;">
<b style="color: #575012; font-size: 10pt;">Repository: </b>
kde
</div>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" \
style="border: 1px solid #b8b5a0"> <tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Hi! It's very difficult to extend the l10n-script if you don't \
know it's internal workings, and if all comments are stripped out, so in order to \
get AppStream support into the l10n-script, I created two small bash scripts to \
translate AppStream upstream metadata:
extract_metainfo.sh: This script generates .pot files from metadata
XML files found in a project. Just cd to the directory you want the
resulting pot files to be stored in, then call the script and point it
at the project's source tree you want to be searched for the XML
files.
merge_metainfo.sh: The script merges translation back into the XML
files. Simply cd to a directory which stores .mo files with the
translated data and call the script with the project's source dir as
first parameter.
These scripts illustrate how translation of the XML can be done in
KDE. I would kindly ask the l10n-script developers to take a look at
it any maybe integrate it at the proper places, because they know the
code way better than I do.
The scripts can also be found at:
http://people.freedesktop.org/~mak/appstream/kde-asmetadata-l10n.tar.gz
(I also included a demo XML file there)
If you have questions, please let me know!
Cheers,
Matthias
</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0"> <tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">* Finds AppStream metadata in project source directories
* .pot extraction works
* Merging translation to untranslated files works
* Merging new translation into already translated metadata files works (without \
duplicating entries)
* Resulting files are valid AppStream metadata files (compliance-check passed)
</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">
<li>trunk/l10n-kde4/scripts/extract_metainfo.sh <span style="color: \
grey">(PRE-CREATION)</span></li>
<li>trunk/l10n-kde4/scripts/as-metainfo.its <span style="color: \
grey">(PRE-CREATION)</span></li>
<li>trunk/l10n-kde4/scripts/update_translations <span style="color: \
grey">(1384853)</span></li>
</ul>
<p><a href="https://svn.reviewboard.kde.org/r/7106/diff/" style="margin-left: \
3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic