vpip.execute
A utility to spawn subprocess and capture the output.
-
vpip.execute.execute(cmd, capture=False)
Execute a command.
- Parameters:
cmd (list or str) – Command. If cmd
is a str
, the command would be
invoked with shell.
capture (bool) – If True
then enter the capture mode: process output
will be captured and the function will return a generator yielding
lines of the output.
- Return type:
Iterator[str] or None