in reply to Running multiple jobs with dependencies
Not that the system suggestion's not a bad idea, but if you're going to call wait why not just have the child return a zero/non-zero exit status and look at $? rather than using the file.