From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by 10.96.157.163 with SMTP id wn3csp56346qdb; Thu, 3 Apr 2014 13:13:54 -0700 (PDT) X-Received: by 10.60.40.39 with SMTP id u7mr6103178oek.56.1396556034135; Thu, 03 Apr 2014 13:13:54 -0700 (PDT) Return-Path: Received: from rubyforge.org ([50.56.192.79]) by mx.google.com with ESMTP id e10si5283169oey.40.2014.04.03.13.13.53 for ; Thu, 03 Apr 2014 13:13:54 -0700 (PDT) Received-SPF: pass (google.com: domain of sup-talk-bounces@rubyforge.org designates 50.56.192.79 as permitted sender) client-ip=50.56.192.79; Authentication-Results: mx.google.com; spf=pass (google.com: domain of sup-talk-bounces@rubyforge.org designates 50.56.192.79 as permitted sender) smtp.mail=sup-talk-bounces@rubyforge.org; dkim=neutral (body hash did not verify) header.i=@gmail.com; dmarc=fail (p=NONE dis=NONE) header.from=gmail.com Received: from localhost.localdomain (localhost [127.0.0.1]) by rubyforge.org (Postfix) with ESMTP id A96C32E1EF; Thu, 3 Apr 2014 20:13:54 +0000 (UTC) Received: from mail-we0-f179.google.com (mail-we0-f179.google.com [74.125.82.179]) by rubyforge.org (Postfix) with ESMTP id 055952E188 for ; Thu, 3 Apr 2014 20:12:52 +0000 (UTC) Received: by mail-we0-f179.google.com with SMTP id x48so2461006wes.10 for ; Thu, 03 Apr 2014 13:12:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id:user-agent :content-transfer-encoding:mime-version:content-type; bh=2DAF2M/S43xgPLsdKEfqmFsMzGsSrej57yS0pTXR3M4=; b=b9yy6+v6/O3hpgwWjcmLajQ4xHf7m4sg+5buSrbR4hCtWVru/56yP/PTmJsOD/0gK7 EshoYqC71NOmKj6jlWq/qh0BVrcbRPINo1plnlZyMgQSZTkHwkhHh1DUBPxmYjJwD/HP uWsaUEgXGDtgDfpouQkNtKUfQb+l52h95Pu3GwxuaiXkYVo/75giK+DG2YpAq613hVN9 j37HrviPPJR4jtK4TNHsDfWI5/g7J5EgP/SkvE3JNkC7pWVP5TywdLGEWHHVHDK5WgS9 H/h+ofXPBMjTber/9tXdC76+OidatoXPja1v7hatjGSv78SdRuiOCgkqPoZsozv8zD8J 7s/A== X-Received: by 10.180.98.35 with SMTP id ef3mr41009133wib.39.1396555970574; Thu, 03 Apr 2014 13:12:50 -0700 (PDT) Received: from localhost.localdomain (155-29-190-109.dsl.ovh.fr. [109.190.29.155]) by mx.google.com with ESMTPSA id xm20sm136954wib.19.2014.04.03.13.12.48 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 03 Apr 2014 13:12:49 -0700 (PDT) Received: from localhost (localhost.localdomain [IPv6:::1]); by localhost.localdomain (OpenSMTPD) with ESMTP id 75b0b7ad; for ; Thu, 3 Apr 2014 20:12:43 +0000 (UTC) From: Matthieu Rakotojaona To: sup-talk X-pgp-key: http://otokar.looc2011.eu/static/matthieu.rakotojaona.asc Date: Thu, 03 Apr 2014 22:12:38 +0200 Message-Id: <1396555234-sup-5195@kpad> User-Agent: Sup/git MIME-Version: 1.0 Subject: [sup-talk] Automatic watch of IMAP folder X-BeenThere: sup-talk@rubyforge.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: User & developer discussion of Sup List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============4579526071579386183==" Sender: sup-talk-bounces@rubyforge.org Errors-To: sup-talk-bounces@rubyforge.org --===============4579526071579386183== Content-Transfer-Encoding: 8bit Content-Type: multipart/signed; protocol="application/pgp-signature"; boundary="=-1396555963-440885-29441-2739-1-=" --=-1396555963-440885-29441-2739-1-= Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable 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 --=-1396555963-440885-29441-2739-1-= Content-Disposition: attachment; filename="signature.asc" Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQJ8BAEBCgBmBQJTPcC7XxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQwNkQ3NDcxMDJFRUU4MEYwRTY4MzQwMkEz QTc0RTE5NDVDM0Q5NzIyAAoJEDp04ZRcPZciTssQAIB/kVM4x00Xi6iCc56ySO7n GqLS0mxEOSVfdZxtAZ6s6tmbTLfn760fMa1DccPW/DbgNDfIY8W5AVqLejUUfOoE 1MDYsH7K9xz4w63JlP9ELvF9s8U+pm39J/xiBvF9nM2Q1YIKxl6VmJtsNXU+GsnZ alDjf2SGwzOlLUnBCZAT6DL/vJxeODBcefnXBq6AQzkQlRqrLZhOhGr9oeoPH2Z+ jmhMKGirQVj5onKeQUIGoho8d/UqzwHxGiRCUhrjCeeVihxhJpF1NecS7YhVaZN1 02qrffZQjdiqLvTvPPEtPYRpcOQhrhAoM+qRW+z4jEouOlt7UFx81+C586cmdwXg MBoU2YKDXaKPl+9RvSvlDwtv7+/5TESX4b1HdDLURohz1/lP8J6MaDIHmiEIWP7Y dOTJAdlmkLVkppOcGjFPRkUfrs66HLnYPp/jY5vltkgBXXfLJLaPiKHbWgZXpVg0 IltHSjKPZbCnBndqc40dHqCmU6M7bNL/pHiBxK7roraB0ghJgUBhH0CMUiELfOuP BJU1Fm85kW3kdIKvTpdz1kRmd4t66G4IWsBxwEMe5O+q8E1PgxzxwGsBre6vj+sp tj6r0ELRd5jO9Y0xPS5URziCGx6PYTfMHq1IAW52iwpBZp+jy0Xhn69DMe4NmEOa +03vXD93VrBNWbdn5NWA =dwgS -----END PGP SIGNATURE----- --=-1396555963-440885-29441-2739-1-=-- --===============4579526071579386183== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ sup-talk mailing list sup-talk@rubyforge.org http://rubyforge.org/mailman/listinfo/sup-talk --===============4579526071579386183==--