Types
Running or finished process
Methods
Bool(p:Process)
Wait for process to finish and see whether exit code is 0
finished_ok(p:Process)
Decide whether /bin/false process finished normally: exit code must be 1.
finished_ok(p:Process)
Decide whether specific process finished normally: exit code must be 0 or 1.
kill(p:Process, sig:Int=15)
Send signal to a Process. Uses KILL(2).
Throws InvalidArgument if Process does not have "pid".
Throws KillFail on error.
lines(p:Process)
Wait for the process and return lines of its stdout.
lines(p:Process, cb:Fun)
Iterate lines of Process' stdout, calling cb with successive lines.
Warning: current implementation waits for the process to finish and accumulates all its stdout.
Str(p:Process)
Wait for the process to finish and return its standard output.
to_exit_code(p:Process)
Convert Process to exit code. Waites for the process to finish and uses its exit code.
wait(p:Process)
Wait for the process to finish. Waits for reading and writing threads to finish first.