atexit/signal for non-interactive jobs

2010-05-26 Thread kj
I want to implement clean-up functions for scripts to be run on a Linux cluster (through LSF). The goal is to make sure that a minimal wrap-up sequence (print diagnostic info, flush buffers, etc.) gets executed if the job is terminated for some reason. (The most common reason for premature

Re: atexit/signal for non-interactive jobs

2010-05-26 Thread Cameron Simpson
On 26May2010 20:19, kj no.em...@please.post wrote: | If I start the script interactively and after a few seconds (i.e. | before it terminates) I hit Ctrl-C (which sends a TERM signal to | the process), the wrapup function gets called as desired (although | this action appears to be triggered by