classification
Title: Patch to make 'idle.bat' run idle.pyw using appropriate Python interpreter (so 3.1's idle.bat does not accidently use python26.exe)
Type: behavior Stage:
Components: IDLE, Windows Versions: Python 3.1, Python 2.6
process
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: srid, trentm (2)
Priority: Keywords patch

Created on 2009-06-29 20:45 by srid, last changed 2009-06-29 21:36 by trentm.

Files
File name Uploaded Description Edit Remove
idle-use-curr-py.patch srid, 2009-06-29 20:45
Messages (1)
msg89875 - (view) Author: Sridhar Ratnakumar (srid) Date: 2009-06-29 20:45
On Mon, 29 Jun 2009 09:56:53 -0700, Trent Mick <trentm@activestate.com>
wrote:

> Sridhar Ratnakumar wrote:
>> I installed ActivePython-3.1 to C:\Python31 but disabled the 
installer
>> option "Register as default Python" .. because, I use Python-2.6 by  
>> default.
>>
>> However, this disabling broke 3.1's IDLE. Clicking on 'idle.bat' or
>> 'idle.py' or 'idle.pyw' in C:\Python31\Lib\idle\ directory opens 
Python
>> 2.6's IDLE.
>>
>> Since the installer knows the path to Python - C:
\Python31\python.exe -
>> does it make sense to patch the idle.bat file to use this binary?
>
> IIRC there is a special NT batch file syntax that you can use do that
> idle.bat will look for python.exe in a relative path, so that you 
won't
> have to patch idle.bat after install (which would be a pain).
>
> Here, use this for idle.bat:
>
>    @echo off
>    set CURRDIR=%~dp0
>    start %CURRDIR%..\..\pythonw.exe idle.pyw
>
> Perhaps you could add a bug to core Python to change idle.bat to be 
that?
>
>
> Trent
>
History
Date User Action Args
2009-06-29 21:36:54trentmsetnosy: + trentm
2009-06-29 20:45:21sridcreate