Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Backgroun job return code



On Feb 6,  1:09pm, Slawek Zak wrote:
}
} Threading is really not necessary to get this. One idea would be
} calling the TRAPEXIT function for *all* jobs, not only the foreground

No, TRAPEXIT refers to the exit of the shell itself, or of a shell
function, not of a job (not even the foreground job).

What you really want is for TRAPCHLD to have access to the exit status
(and possibly other job data) of the child that caused it to be called.



Messages sorted by: Reverse Date, Date, Thread, Author