Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id EA456431E82 for ; Tue, 10 Jul 2012 09:48:33 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -2.29 X-Spam-Level: X-Spam-Status: No, score=-2.29 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_MED=-2.3, T_MIME_NO_TEXT=0.01] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0J4aqqR89-I4 for ; Tue, 10 Jul 2012 09:48:33 -0700 (PDT) Received: from outgoing-mail.its.caltech.edu (outgoing-mail.its.caltech.edu [131.215.239.19]) by olra.theworths.org (Postfix) with ESMTP id 1D190431E64 for ; Tue, 10 Jul 2012 09:48:33 -0700 (PDT) Received: from fire-doxen.imss.caltech.edu (localhost [127.0.0.1]) by fire-doxen-postvirus (Postfix) with ESMTP id 6D63C32804E; Tue, 10 Jul 2012 09:48:30 -0700 (PDT) X-Spam-Scanned: at Caltech-IMSS on fire-doxen by amavisd-new Received: from finestructure.net (adsl-76-240-184-246.dsl.irvnca.sbcglobal.net [76.240.184.246]) (Authenticated sender: jrollins) by fire-doxen-submit (Postfix) with ESMTP id 0AA892E50B51; Tue, 10 Jul 2012 09:48:22 -0700 (PDT) Received: by finestructure.net (Postfix, from userid 1000) id 2B782868; Tue, 10 Jul 2012 09:48:21 -0700 (PDT) From: Jameson Graef Rollins To: Sebastien Binet , Jani Nikula Subject: Re: post-new [was: Re: query on a subset of messages ?] In-Reply-To: <871ukk2ayc.fsf@cern.ch> References: <871ukl5oj7.fsf@cern.ch> <87ehol2aku.fsf@servo.finestructure.net> <87wr2c3mtj.fsf@cern.ch> <87r4sk3lxu.fsf@cern.ch> <8739503llz.fsf@servo.finestructure.net> <871ukk2ayc.fsf@cern.ch> User-Agent: Notmuch/0.13.2+54~ga0426dc (http://notmuchmail.org) Emacs/23.4.1 (x86_64-pc-linux-gnu) Date: Tue, 10 Jul 2012 09:48:17 -0700 Message-ID: <87629vzhny.fsf@servo.finestructure.net> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Cc: Notmuch Mail X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 Jul 2012 16:48:34 -0000 --=-=-= On Tue, Jul 10 2012, Sebastien Binet wrote: > ok. I thought using the post-new hook would have saved some i/o > resources over my current setup: > offlineimap.postsynchook = ~/emacs/notmuch-lib/notmuch-tag.sh > > where notmuch-tag.sh is (in pseudo-code): > ## > /usr/bin/notmuch new > > for tag,query in tag-queries: > tag_new $tag $query > > ## > > is there any advantage of using post-new compared to this setup ? The hooks are just there for convenience, and as Jani says, they're executed any time notmuch new is run, in any context. In your setup it looks like it would also save you having to maintain another script (notmuch-tag.sh) since that script in it's entirety could just be the post-new script, and the offlineimap.postsynchook could just execute notmuch new directly. jamie. --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iQIcBAEBCAAGBQJP/FzRAAoJEO00zqvie6q8HV0QALkI+b+tBC0TaE9Y8AtH/njN GEj7zzw5bdgZIzv/hG6/sRWsnkwst9+paSqqqp72G4A4FWJfsI8VPaVVTQBCi1VB 1WBBBXewtelbP/vyquXlMyaAA+NnLJ4/SCFH0SSKpgrjy1AfRNQUrTHkZrAZGVCC W8O3zLSKcRCCvsQm1ZTahgsnrc194ucVwHvgeKnD/Z/KmuB2mb3cVfXrssBjCnIy kMZzQD1aYEyZVb7arFiyJWQj1BXOxSG+BT/63GIb9T7WrCQjVKi9f8QdH1vp4iiq 6SmV8vGt1FvDbczr4xkn0nChTCyOnnP2FbV08j64mNV/EFkZw8i02ccMD/91fQck pcaI8kC1cbEAzOA+0gEsgVNl8NdT1rTKkKWByxcUZUDHi8FxwnW31p+MmcvTFoPz qdwucFRDx4AUd4MpmwQ6wPp+NlQLlx6Je81FbfHCfCqqJmKYD3jDrjtx3DaxzfxY pnbBN5fRBG82NmxJH0jCQQrW21Qd3RDvThV1UV2FoBJPW/eJTV1CrTwAya8/DtjX IR0X1QSzDkg4VmsfOTqIEceLMHzq7CPShbzwiNEfPE8i+twg15H3OYmgqRMsuVBC RbYyK52PSiNLnfNIT3AGLMaRMQ1p7u7hMlhLw7yyf51wFv06E0wsKmMBTDvxok36 1u0I7DsK4RO7QOgRWgpC =Hpnj -----END PGP SIGNATURE----- --=-=-=--