Mailinglist Archive: opensuse-translation (44 mails)

< Previous Next >
Re: [opensuse-translation] Translation of http://www.opensuse.org/
  • From: Guillaume Gardet <guillaume.gardet@xxxxxxx>
  • Date: Wed, 06 Jun 2012 18:54:33 +0200
  • Message-id: <4FCF8B49.6020402@free.fr>
Hi,

Le 31/05/2012 15:42, Guillaume Gardet a écrit :
Hi,

Le 30/05/2012 18:24, Luiz Fernando Ranghetti a écrit :
2012/5/30 Thomas Schmidt<tom@xxxxxxxxxxxx>:
On 30.05.2012 16:07, Luiz Fernando Ranghetti wrote:
2012/5/30 Thomas Schmidt<tom@xxxxxxxxxxxx>:
On 30.05.2012 11:21, Guillaume Gardet wrote:

Hi,

Le 29/05/2012 14:24, Thomas Schmidt a écrit :

On 29.05.2012 14:15, Guillaume Gardet wrote:

Hi,

does anyone know how is translated http://www.opensuse.org/ ?
There are no PO file for it. I think it was in a raw text file or a
spreadsheet or something like that.
Translation of http://www.opensuse.org/fr/ (French) is not complete.
Who
should I contact to get the strings translated?

Cheers,

Guillaume

Please do a pull request on github for this file:
https://github.com/openSUSE/landing-page/blob/master/fr/index.shtml
or send the translated version here.

Greetings

In fact, it is the whats_hot.html page which does not exist for french
and
thus we use the english one. Could I translate it and use it as it is
done for "de" or "es" for example?


Sure, just add the frech version of whats_hot and include it in
index.shtml.
Similar to how it's done for de.


Hi

I think we can make the same as coolo does for software.o.o. He
creates .po files for that page and let the i18n team translate that
page. The advantage is that when tha page changes (generally once for
release) the mantainer or AJ doesn't need to ask for translation, as
the updated files will be on i18n svn.

I made a test with po4a-gettextize (package po4a) and html2po (package
translate-toolkit) for index.shtml
Both create .po files, po4a with 42 strings and html2po with 29
strings. Why the difference?
html2po extract some tags inside a string while po4a not. See below 2
example strings:

html2po

1:
<strong>openSUSE</strong> is a free and Linux-based operating system for
your PC, Laptop or Server. You can surf the web, manage your e-mails and
photos, do office work, play videos or music and<em>have a lot of
fun!</em>

and this:

2:
<input type="hidden" name="language" value="en" /> <select
id="searchscope"
name="searchscope"> <option value="blogs">search in blog-posts</option>
<option value="news">search the news</option> <option
value="software">search for software</option> <option value="wiki"
selected="selected">search in help-section</option> </select> <input
type="text" name="searchstring" class="textfield" /> <input type="image"
alt="run search" title="run search" class="searchbutton"
src="http://static.
opensuse.org/hosts/www.o.o/images/frontpage/magnifier.png" />

po4a-gettextize

1a:
openSUSE

1b:
is a free and Linux-based\n
operating system for your PC, Laptop or Server.\n
You can surf the web, manage your e-mails and photos,\n
do office work, play videos or music and\n

1c:
have a lot of fun!

and

2a:
search in blog-posts

2b:
search the news

2c:
search for software

2d:
search in help-section

For what's hot page, the number of resulting strings is 7 for html2po
and 30 for po4a-gettextize

Regards,

Luiz

Hi, I think the second approach is better, as it avoids breakage of the html
by
broken translations. But it also could cause trouble when different
languages need
a different sentence structure.
We would need a script set that automates the extraction and merging from
the lcn
repository. I can give you access to the git repo if you would like to work
on that.

Hi,

Unfortunatly I don't know to much for create a script, that's why I
suggest to look/investigate how coolo does the same think for
software.opensuse.org.

I started to write a script using html2po but there are some bugs (e.g.:
missing things when it is not translated and some inputs are not in the POT and
removed in the resulting html file) whereas po4a seems to handle things
correctly.
I will post my scripts here once it works great.

After some testing it seems my scripts to maintain those pages with PO files
work. You can find them here:
http://guillaume.gardet.free.fr/openSUSE_org/scripts_for_PO/make_POT.sh
http://guillaume.gardet.free.fr/openSUSE_org/scripts_for_PO/make_PO_to_HTML.sh

You must clone the git tree and copy the scripts at the root.

Calling make_POT.sh will create the POT file ./50-pot/opensuse_org.pot from en
HTML files.

Then, this POT file must be sent/copied to the openSUSE i18n server POT folder
(in trunk). PO files will be generated/merged there for translation for each
lang.

Then, you call make_PO_to_HTML.sh to get the translated PO files from the i18n
server and generate HTML files from those PO files.

Currently, sync with i18n server does not work since PO files are not there.
HTML files are generated only if more than 50% of the PO is translated but it
can be changed in the script.

If you want to test the scripts, you can get the POT with no problem (with
make_POT.sh ) but you have to generate the PO manually for your lang with
msginit from POT, translate it and copy it to the $lang/po/ folder. Finally,
call make_PO_to_HTML.sh to generate the HTML files.

Could you please test it for your language ? I tested for French.

If peoples are OK who can add those scripts and execute them on the git server
? (I have no commit rights).
I have commit rights for i18n server but it would make more sense if the
maintainer(s) of the landing page could do it. (You just need to copy the
latest POT file when english HTML files are modified).

Cheers,

Guillaume

--
To unsubscribe, e-mail: opensuse-translation+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: opensuse-translation+owner@xxxxxxxxxxxx

< Previous Next >