SyntaxFix
Write A Post
Hire A Developer
Questions
Another option is it to have the script set itself as the process group leader, and trap a killpg on your process group on exit.