Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
From: Matthieu Rakotojaona <matthieu.rakotojaona@gmail.com>
To: sup-talk <sup-talk@rubyforge.org>
Subject: [sup-talk] Automatic watch of IMAP folder
Date: Thu, 03 Apr 2014 22:12:38 +0200	[thread overview]
Message-ID: <1396555234-sup-5195@kpad> (raw)


[-- Attachment #1.1: Type: text/plain, Size: 930 bytes --]

Hello suppers,

I'm pretty sure some of you sync their mails from some IMAP server
somewhere, maybe Gmail even. I've written a little script that:

- allows you to watch your favorite IMAP folder ("[Gmail]/All mail" by
  default)
- on your favorite server ("imaps://imap.gmail.com" by default)
- with your login/password
- run a custom command("offlineimap -u Quiet") whenever a new mail
  arrives (triggered by an IDLE message)

The script is very simple, but should fit your needs without problems
(feel free to make it a little bit more flexible if you want to)

I've been running it in a tmux for a few days now, and it works good.
The real magic though is done by OfflineIMAP, which makes sure your
mails aren't eaten... and that allows me to be dirty on the details of
external script calls.

The script lives at
https://github.com/rakoo/idlewatch/blob/master/idlewatch.rb

-- 
Matthieu Rakotojaona

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 966 bytes --]

[-- Attachment #2: Type: text/plain, Size: 140 bytes --]

_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk

             reply	other threads:[~2014-04-03 20:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-03 20:12 Matthieu Rakotojaona [this message]
2014-04-03 20:23 ` Gaute Hope

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1396555234-sup-5195@kpad \
    --to=matthieu.rakotojaona@gmail.com \
    --cc=sup-talk@rubyforge.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox