check for the presence of an external program on the path
Trent Mick
trentm at ActiveState.com
Mon Nov 17 12:55:20 EST 2003
[Fernando Rodriguez wrote]
> Hi,
>
> How can I find out if an executable is available in the path?
There is a Python implementation of 'which' that does that here:
http://starship.python.net/~tmick/#which
>>> import which
>>> which.which("python")
'C:\\Python22\\python.EXE'
Cheers,
Trent
--
Trent Mick
TrentM at ActiveState.com
More information about the Python-list
mailing list