Python path on windows

Gisle Vanem gvanem at yahoo.no
Sat Feb 21 06:05:46 EST 2015


Dave Angel wrote:

> Finally, when py.exe starts, it reads that first (shebang) line, and decides which python interpreter to actually use.

py.exe? Do you mean python.exe?

Is there a way to make python.exe ignore all Shebang lines
in all scripts? I had many generated .py-files with:
   #!g:\ProgramFiler\Python27\python.EXE

After transferring my Python tree to a new Win-8.1 PC, my Python
tree was installed under "f:\ProgramFiler\" and my CD-ROM on "g:\"

This caused those scripts to access my CD-ROM or pop-up a Win-GUI
error dialogue if no CD-ROM was in the drive. Irritating.


-- 
--gv



More information about the Python-list mailing list