En Sat, 16 Jan 2010 05:16:14 -0300, Gertjan Klein <gkl...@xs4all.nl> escribió:

Gabriel Genellina wrote:

En Thu, 14 Jan 2010 08:21:28 -0300, luis <soli...@gmail.com> escribió:

Is there any way to indicate the version of the python interpreter
must use a script?

See http://www.effbot.org/zone/exemaker.htm
It uses the #! line to determine which version to load, resembling the
Unix way.
(I've written a variant of the same idea but isn't ready yet)

I'd be interested to see what you've come up with, if you care to share.
I've been thinking about something like this as well. Exemaker, for me,
is the wrong solution, because it requires making an .exe file for every
script you want to run this way.

The advantage is that Task Manager shows the right program name, instead of always "python.exe". (You don't have to *make* an .exe for every script, just rename/copy it.) If you don't care, the recipe posted by Duncan Booth is as close as a #! line as its gets.

--
Gabriel Genellina

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to