try-process ( desc -- )
Operating system processes > Launching processes

Prev:run-process ( desc -- process )
Next:run-detached ( desc -- process )


Vocabulary
io.launcher

Inputs and outputs
desca launch descriptor


Word description
Launches a process and waits for it to complete. If it exits with a non-zero status code, throws a process-failed error.

Examples
USING: continuations io.launcher prettyprint ; [ "i-dont-exist" try-process ] [ ] recover .
T{ process-failed { process T{ process { command "i-dont-exist" } { environment H{ } } { environment-mode +append-environment+ } { group +same-group+ } { status 255 } } } }


See also
run-process, run-detached

Definition