On 26/1/2006, at 19:54, m-junk@still-crazy.org wrote:
but then it occurred to me that it ought to be easy for TM to support a more scripter-friendly version of the same protocol, e.g. [...]
Have a look at stakeout: http://michael-mccracken.net/blog/blosxom.pl/ 2004/07/28
This will allow you to have your script notified when the file is saved (but not closed, for which there is mate -w).
As for receiving AppleScript events from a shell tool, that's not really possible AFAIK because the sender needs to have the receivers four character code, which is something only “real” applications have.