A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2005-September/056311.html below:

[Python-Dev] Replacement for print in Python 3.0

[Python-Dev] Replacement for print in Python 3.0Bob Ippolito bob at redivi.com
Thu Sep 8 19:08:53 CEST 2005
On Sep 8, 2005, at 5:42 AM, Barry Warsaw wrote:

> On Wed, 2005-09-07 at 15:07, Bob Ippolito wrote:
>
>
>> I was also able to easily automate the process of extracting strings
>> to create that spreadsheet.  I wrote a simple script that parsed the
>> Python modules and looked for function calls of "_" whose only
>> argument was a constant string.  Worked great, and it was easy to  
>> write.
>>
>
> I don't think enough people know about Tools/i18n/pygettext.  It does
> all the extractions for you, producing a GNU gettext compatible .pot
> file.  You can even teach it to recognize extraction keywords other  
> than
> the default _().  printf() should be easy to recognize, although we
> might have to make a slight modification since IIRC, pygettext will  
> only
> extract strings from keyword functions with exactly one argument.   
> That
> should be easy to fix.

You're right, I think Tools is probably a bad place for anything.  If  
it's not part of the stdlib, I'll likely never find it.

-bob

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4