shell::run

Function finish_run

Source
fn finish_run(background: bool, job: Job, jobs: &mut Jobs) -> i32
Expand description

Finish a job run.

If not a background job will wait for proc to end and return the exit status or -66 if the wait fails. If it is a background job then return the pid of the last proc in the job. Also sets the LAST_STATUS env var to the exit status (if not background) or 0 if a background job.