Program, Application, and Software

Steve Holden steve at holdenweb.com
Fri Nov 19 11:53:01 EST 2010


On 11/19/2010 9:22 AM, Martin Gregorie wrote:
[...]
> Indeed, 
> it doesn't make sense there since executables are limited to .BAR or .CMD 
> files, which are directly interpreted by the command processor, and .EXE 
> or .COM files, which must be compiled before they can be run. AFAIK 
> there's no way you can mark anything else, such as an awk, Perl or Python 
> source file, as executable since there is no 'executable' attribute in 
> any Windows filing system.

Under Windows you use the PATHEXT mechanism to mark an extension as
executable. Then finding a file with that extension on the PATH will
trigger it to be run by the registered interpreter. As far as I know,
anyway.

By default on my Vista system I see PATHEXT contains

C:\Users\sholden\workspace\Python3_Lesson3\src>echo %PATHEXT%
.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC

regards
 Steve
-- 
Steve Holden           +1 571 484 6266   +1 800 494 3119
PyCon 2011 Atlanta March 9-17       http://us.pycon.org/
See Python Video!       http://python.mirocommunity.org/
Holden Web LLC                 http://www.holdenweb.com/




More information about the Python-list mailing list