title: How to write a unix script that gets notified with IMAP IDLE from Gmail?
body: <p>I'm looking for a way to get notified in my unix system for new email. I know gmail supports IMAP IDLE, what is the best way to make use of that feature? Any programming language is fine, as long as it is supported in linux/unix. </p>