[Tutor] Is an executable available?

Alan Gauld alan.gauld at freenet.co.uk
Mon Feb 14 21:27:10 CET 2005


> I am working from within python and want to know the best way to
know if
> a certain package is installed for use on my machine.

You mean a Python package or a software package in general terms?

> I want to know from within python that a specific executable file is
on
> my path where I could actually run the command from a prompt in a
system
> shell.

OS?

> I don't want to restrict exacltly where the file is and I don't want
to
> do a general try catch.
>
> Are there any simple one or two liners that anyone is aware of?

Its partly OS dependant so we need a wee bit more info.

Alan G.



More information about the Tutor mailing list