translation tools

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

translation tools

robhealey1
Greetings:

I was wondering if it were possible to change po/check_po to po/check_po.py and then we could import it into other python functionality?

Would this compromise its other functionality though?  Would it still remain usable?

--
Sincerely yours,
Rob G. Healey



------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Gramps-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-devel
Reply | Threaded
Open this post in threaded view
|

Re: translation tools

jerome
Hi,


We should have no problem by using 'check_po.py' (or a new name) because
it is a 'standalone' maintenance and testing script.

Note, it is already possible to call it without '.py' extension!

pythonCmd = os.path.join(sys.prefix, 'bin', 'python')

os.system('''%(python)s ./check_po --skip-fuzzy ./%(lang.po)s >
%(lang)s.txt''' % {'python': pythonCmd, 'lang.po': arg, 'lang': arg[:2]})

'shutil', temp files or others commands should be also able to run this
module whatever an extension or not.

We will only have to update the documentation and references (wiki)
after having renamed it!


Jérôme



Rob Healey a écrit :

> Greetings:
>
> I was wondering if it were possible to change po/check_po to
> po/check_po.py and then we could import it into other python functionality?
>
> Would this compromise its other functionality though?  Would it still
> remain usable?
>
> --
> Sincerely yours,
> Rob G. Healey
>
>
>
> ------------------------------------------------------------------------
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Gramps-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gramps-devel


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Gramps-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-devel
Reply | Threaded
Open this post in threaded view
|

Re: translation tools

DS Blank
On Sat, May 12, 2012 at 3:54 AM, Jérôme <[hidden email]> wrote:
> Hi,
>
>
> We should have no problem by using 'check_po.py' (or a new name) because
> it is a 'standalone' maintenance and testing script.
>
> Note, it is already possible to call it without '.py' extension!

I think Rob is wondering how to use it directly from Python, without
"shelling-out".

You could either copy it, or make a link to it. Or just rename it
("./check_po.py ..." works fine as a shell command).

But, you can also just:

>>> execfile("check_po")

which then makes all of the elements available here.

-Doug

> pythonCmd = os.path.join(sys.prefix, 'bin', 'python')
>
> os.system('''%(python)s ./check_po --skip-fuzzy ./%(lang.po)s >
> %(lang)s.txt''' % {'python': pythonCmd, 'lang.po': arg, 'lang': arg[:2]})
>
> 'shutil', temp files or others commands should be also able to run this
> module whatever an extension or not.
>
> We will only have to update the documentation and references (wiki)
> after having renamed it!
>
>
> Jérôme
>
>
>
> Rob Healey a écrit :
>> Greetings:
>>
>> I was wondering if it were possible to change po/check_po to
>> po/check_po.py and then we could import it into other python functionality?
>>
>> Would this compromise its other functionality though?  Would it still
>> remain usable?
>>
>> --
>> Sincerely yours,
>> Rob G. Healey
>>
>>
>>
>> ------------------------------------------------------------------------
>>
>> ------------------------------------------------------------------------------
>> Live Security Virtual Conference
>> Exclusive live event will cover all the ways today's security and
>> threat landscape has changed and how IT managers can respond. Discussions
>> will include endpoint security, mobile security and the latest in malware
>> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>>
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Gramps-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/gramps-devel
>
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> Gramps-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gramps-devel

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Gramps-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-devel