t.p.procutils : module documentation

Part of twisted.python View Source

Utilities for dealing with processes.
Function which Search PATH for executable files with the given name.
def which(name, flags=os.X_OK): (source)
Search PATH for executable files with the given name.

On newer versions of MS-Windows, the PATHEXT environment variable will be set to the list of file extensions for files considered executable. This will normally include things like ".EXE". This fuction will also find files with the given name ending with any of these extensions.

On MS-Windows the only flag that has any meaning is os.F_OK. Any other flags will be ignored.

ParametersnameThe name for which to search. (type: str)
flagsArguments to os.access. (type: int)
A list of the full paths to files found, in the order in which they were found.
Returns (type: list)
API Documentation for Twisted, generated by pydoctor at 2012-09-01 11:44:56.