GRASS Programmer's Manual
6.4.2(2012)
|
Data Structures | |
class | STARTUPINFO |
class | pywintypes |
class | Popen |
Functions | |
def | call |
Run command with arguments. | |
def | list2cmdline |
Variables | |
tuple | mswindows = (sys.platform == "win32") |
list | __all__ = ["Popen", "PIPE", "STDOUT", "call"] |
tuple | MAXFD = os.sysconf("SC_OPEN_MAX") |
int | False = 0 |
int | True = 1 |
list | _active = [] |
int | PIPE = 1 |
int | STDOUT = 2 |
def compat.subprocess.call | ( | args, | |
kwargs | |||
) |
Run command with arguments.
Wait for command to complete, then return the returncode attribute.
The arguments are the same as for the Popen constructor. Example:
retcode = call(["ls", "-l"])
Definition at line 404 of file subprocess.py.
Referenced by N_alloc_les_callback_2d(), and N_alloc_les_callback_3d().
def compat.subprocess.list2cmdline | ( | seq | ) |
Translate a sequence of arguments into a command line string, using the same rules as the MS C runtime: 1) Arguments are delimited by white space, which is either a space or a tab. 2) A string surrounded by double quotation marks is interpreted as a single argument, regardless of white space contained within. A quoted string can be embedded in an argument. 3) A double quotation mark preceded by a backslash is interpreted as a literal double quotation mark. 4) Backslashes are interpreted literally, unless they immediately precede a double quotation mark. 5) If backslashes immediately precede a double quotation mark, every pair of backslashes is interpreted as a literal backslash. If the number of backslashes is odd, the last backslash escapes the next double quotation mark as described in rule 3.
Definition at line 415 of file subprocess.py.
list compat::subprocess::__all__ = ["Popen", "PIPE", "STDOUT", "call"] |
Definition at line 380 of file subprocess.py.
list compat::subprocess::_active = [] |
Definition at line 394 of file subprocess.py.
int compat::subprocess::False = 0 |
Definition at line 391 of file subprocess.py.
int compat::subprocess::MAXFD = os.sysconf("SC_OPEN_MAX") |
Definition at line 383 of file subprocess.py.
tuple compat::subprocess::mswindows = (sys.platform == "win32") |
Definition at line 344 of file subprocess.py.
int compat::subprocess::PIPE = 1 |
Definition at line 400 of file subprocess.py.
int compat::subprocess::STDOUT = 2 |
Definition at line 401 of file subprocess.py.
int compat::subprocess::True = 1 |
Definition at line 392 of file subprocess.py.