[Sugar-devel] Poll activty translation with gettext

Jammily Ortigoza jortigozaf at gmail.com
Tue Aug 29 15:47:10 EDT 2017


On Tue, Aug 29, 2017 at 1:59 PM, James Cameron <quozl at laptop.org> wrote:

> http://wiki.laptop.org/go/Internationalization_in_Sugar is deprecated.
>
> Poll activity is translated using translate.sugarlabs.org.
>
> What are you trying to do?
>
> Why not upload translations to translate.sugarlabs.org?
>
> https://github.com/sugarlabs/poll-activity/commits/master shows
> updated POT file and new translations 23 days ago.
>

I want to translate the missing messages.

I can see the updated POT file, but the es.po file is still not updated
with all the strings (msgid) inside the POT file.

As you can see, Poll is fully translated for "es" in translate.sugarlabs.org
but it has missing strings due to staled es.po file. What is the procedure
to update es.po file with latest changes based in POT file into
translate.sugarlabs.org?

>
> https://translate.sugarlabs.org/projects/Poll-Builder/ shows new
> translations only for GuaranĂ­ (Paraguay).
>
> On Tue, Aug 29, 2017 at 11:56:16AM -0400, Jammily Ortigoza wrote:
> > Hi everybody,
> >
> > I'm trying to translate Poll activity using gettext. I followed this
> tutorial
> > [1].
> >
> > I have my POTFILE.in.
> >
> > >> cat POTFILES.in
> > encoding: UTF-8
> > PollSession.py
> > poll.py
> > Widgets.py
> >
> > With the POTFILE.in I generated the .pot file:
> >
> > $pwd
> > $HOME/Activities/Poll.activity
> > $python setup.py genpot
> > $ls $HOME/Activities/Poll.activity/po
> > Poll.pot
> >
> > Following, I generated the es.po file:
> >
> > $msginit -l es
> > $ls $HOME/Activities/Poll.activity/po
> > es.po
> >
> > The es.po file is ok, I can see all the messages to be translated. I did
> the
> > translation an after that I did the last step:
> >
> > msgfmt es.po --output='../locale/es/LC_MESSAGES/[1]
> > org.worldwideworkshop.PollBuilder.mo'
> >
> > Almost all translations work except the ones with the "%s" in the msgid.
> > For example:
> >
> > #: poll.py:367
> > #, python-format
> > msgid "Do you want delete the poll \"%s\"?"
> > msgstr "Desea eliminar la encuesta \"%s\"?"
> >
> > This is still showing in english when I open Poll activity.
> >
> > Does somebody know what am I doing wrong?
> >
> > Regards.
> >
> > --
> > Jammily Ortigoza
> >
> > [1] [2]http://wiki.laptop.org/go/Internationalization_in_Sugar
> >
> > References:
> >
> > [1] http://org.worldwideworkshop.pollbuilder.mo/
> > [2] http://wiki.laptop.org/go/Internationalization_in_Sugar
>
> > _______________________________________________
> > Sugar-devel mailing list
> > Sugar-devel at lists.sugarlabs.org
> > http://lists.sugarlabs.org/listinfo/sugar-devel
>
>
> --
> James Cameron
> http://quozl.netrek.org/
>

Regards.

-- 
Jammily Ortigoza
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sugarlabs.org/archive/sugar-devel/attachments/20170829/44b64a2d/attachment.html>


More information about the Sugar-devel mailing list