Re: [ANNOUNCE] mutt with notmuch support
[notmuch-archives.git] / 60 / 2e671c1ea2f27ecf91e5c10452f685a69295b7
1 Return-Path: <amdragon@mit.edu>\r
2 X-Original-To: notmuch@notmuchmail.org\r
3 Delivered-To: notmuch@notmuchmail.org\r
4 Received: from localhost (localhost [127.0.0.1])\r
5         by olra.theworths.org (Postfix) with ESMTP id C9A9F429E26\r
6         for <notmuch@notmuchmail.org>; Mon, 12 Dec 2011 07:40:52 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -0.7\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5\r
12         tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
13 Received: from olra.theworths.org ([127.0.0.1])\r
14         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
15         with ESMTP id UP7Z69Hd1VTP for <notmuch@notmuchmail.org>;\r
16         Mon, 12 Dec 2011 07:40:52 -0800 (PST)\r
17 Received: from dmz-mailsec-scanner-4.mit.edu (DMZ-MAILSEC-SCANNER-4.MIT.EDU\r
18         [18.9.25.15])\r
19         by olra.theworths.org (Postfix) with ESMTP id 0FE10429E25\r
20         for <notmuch@notmuchmail.org>; Mon, 12 Dec 2011 07:40:52 -0800 (PST)\r
21 X-AuditID: 1209190f-b7f6e6d0000008df-4c-4ee6208284c8\r
22 Received: from mailhub-auth-1.mit.edu ( [18.9.21.35])\r
23         by dmz-mailsec-scanner-4.mit.edu (Symantec Messaging Gateway) with SMTP\r
24         id B6.F9.02271.28026EE4; Mon, 12 Dec 2011 10:40:50 -0500 (EST)\r
25 Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103])\r
26         by mailhub-auth-1.mit.edu (8.13.8/8.9.2) with ESMTP id pBCFenpk015259; \r
27         Mon, 12 Dec 2011 10:40:50 -0500\r
28 Received: from awakening.csail.mit.edu (awakening.csail.mit.edu [18.26.4.91])\r
29         (authenticated bits=0)\r
30         (User authenticated as amdragon@ATHENA.MIT.EDU)\r
31         by outgoing.mit.edu (8.13.6/8.12.4) with ESMTP id pBCFekWb025058\r
32         (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT);\r
33         Mon, 12 Dec 2011 10:40:47 -0500 (EST)\r
34 Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.77)\r
35         (envelope-from <amdragon@mit.edu>)\r
36         id 1Ra81F-0005kO-3p; Mon, 12 Dec 2011 10:42:21 -0500\r
37 Date: Mon, 12 Dec 2011 10:42:21 -0500\r
38 From: Austin Clements <amdragon@MIT.EDU>\r
39 To: Dmitry Kurochkin <dmitry.kurochkin@gmail.com>\r
40 Subject: Re: [PATCH] emacs: support "notmuch new" as a notmuch-poll-script\r
41 Message-ID: <20111212154221.GN2760@mit.edu>\r
42 References: <1323640100-18326-1-git-send-email-jani@nikula.org>\r
43         <87wra26a5u.fsf@gmail.com> <20111211225822.GH2760@mit.edu>\r
44         <CAB+hUn-ADRtZRCq5Ad6H6R2L246EBR8hOSsk4B2yeRsH4kN16w@mail.gmail.com>\r
45         <20111212003103.GI2760@mit.edu> <yf6wra2m6y7.fsf@taco2.nixu.fi>\r
46         <87wra2ay4e.fsf@gmail.com>\r
47 MIME-Version: 1.0\r
48 Content-Type: text/plain; charset=us-ascii\r
49 Content-Disposition: inline\r
50 In-Reply-To: <87wra2ay4e.fsf@gmail.com>\r
51 User-Agent: Mutt/1.5.21 (2010-09-15)\r
52 X-Brightmail-Tracker:\r
53  H4sIAAAAAAAAA+NgFprKKsWRmVeSWpSXmKPExsUixCmqrNuk8MzPYFm3isXVrf3sFk3TnS2u\r
54         35zJbPFm5TxWBxaPnbPusnsc/rqQxePW/dfsHs9W3WIOYInisklJzcksSy3St0vgyli4/Bhj\r
55         wVX+io47J1gaGBt5uhg5OSQETCR+/3nEDGGLSVy4t56ti5GLQ0hgH6PEpdMX2SGcDYwSv6bM\r
56         Z4RwTjJJ9LU2s4C0CAksYZTYf8K7i5Gdg0VAVeJIDkiUTUBDYtv+5YwgtoiAocSti6/AFjAL\r
57         pErMfjCJDcQWFvCS2Pi2G2wKr4C2xJF/x1ggxi9jkrh88hwTREJQ4uTMJywQzVoSN/69BIpz\r
58         ANnSEsv/cYCEOQXUJU7s3MAKYosKqEhMObmNbQKj0Cwk3bOQdM9C6F7AyLyKUTYlt0o3NzEz\r
59         pzg1Wbc4OTEvL7VI10QvN7NELzWldBMjOPQl+XcwfjuodIhRgINRiYc3yfepnxBrYllxZe4h\r
60         RkkOJiVR3i65Z35CfEn5KZUZicUZ8UWlOanFhxglOJiVRHibuYFyvCmJlVWpRfkwKWkOFiVx\r
61         3rpdD/2EBNITS1KzU1MLUotgsjIcHEoSvN/lgRoFi1LTUyvSMnNKENJMHJwgw3mAhu8AqeEt\r
62         LkjMLc5Mh8ifYlSUEuc9A5IQAElklObB9cJS0ytGcaBXhHm/gVTxANMaXPcroMFMQIPjUp6A\r
63         DC5JREhJNTBKfr4kbqAuLmqxuERmvam58nytmPpOl/jOWCaeutk1Pz17HK8cfP5PKdglxF53\r
64         759GnilGK7fceB/1P/1fg7lhYduJJ7td2ra1Ldtven7ytIzLxisYZvPfYeDOaZOafZJ5zeLI\r
65         V5fvZTgXf2osNH7wY4W6m9n14rSDKe4eKZx683McN18U8lNiKc5INNRiLipOBADeUNLVKAMA        AA==\r
66 Cc: Tomi Ollila <tomi.ollila@iki.fi>, notmuch@notmuchmail.org\r
67 X-BeenThere: notmuch@notmuchmail.org\r
68 X-Mailman-Version: 2.1.13\r
69 Precedence: list\r
70 List-Id: "Use and development of the notmuch mail system."\r
71         <notmuch.notmuchmail.org>\r
72 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
73         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
74 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
75 List-Post: <mailto:notmuch@notmuchmail.org>\r
76 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
77 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
78         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
79 X-List-Received-Date: Mon, 12 Dec 2011 15:40:52 -0000\r
80 \r
81 Quoth Dmitry Kurochkin on Dec 12 at  2:21 pm:\r
82 > On Mon, 12 Dec 2011 12:15:44 +0200, Tomi Ollila <tomi.ollila@iki.fi> wrote:\r
83 > > On Sun, 11 Dec 2011 19:31:03 -0500, Austin Clements <amdragon@MIT.EDU> wrote:\r
84 > > > \r
85 > > > So here's another idea, prefaced with a rant.\r
86 > > > \r
87 > > > It's bothered me for a long time that notmuch-emacs didn't just know\r
88 > > > by default how to check for new mail.  What MUA doesn't know how to\r
89 > > > check for new mail?  Why does a new user of notmuch have to tell it\r
90 > > > how to check for new mail?  Of course, this *had* to be configured\r
91 > > > before because everyone had their own way of checking for new mail.\r
92 > > > Hooks eliminate this unnecessary flexibility and make "notmuch new"\r
93 > > > the one true way to check for new mail---as it ought to be---and in\r
94 > > > turn make the notmuch-poll-script variable obsolete.\r
95 > > > \r
96 > > > So, what about changing the default "" setting of notmuch-poll-script\r
97 > > > from meaning "do nothing and be useless" to meaning "run notmuch new\r
98 > > > (using notmuch-command)"?  It will then automatically do the right\r
99 > > > thing for new users, while still being backward-compatible and\r
100 > > > allowing an escape hatch for bizarre situations.\r
101 > > \r
102 > > +1\r
103 > > \r
104 > > So, it could work like this:\r
105 > > \r
106 > > (defun notmuch-poll ()\r
107 > >   "FIX DOCSTRING"\r
108 > >   (interactive)\r
109 > >   (if (stringp notmuch notmuch-poll-script)\r
110 > >       (if (string= notmuch-poll-script "")\r
111 > >         (call-process notmuch-command nil nil nil "new")\r
112 > >         (call-process notmuch-poll-script))))\r
113 > > \r
114 > > I.e. in case notmuch-poll-script == nil, (or not string)\r
115 > > do nothing. In case notmuch-poll-script == "" execute notmuch new\r
116 > > and if notmuch-poll-script is string with content execute that.\r
117 > > \r
118\r
119 > I think the following scheme would be slightly better and more\r
120 > consistent:\r
121\r
122 > * nil - run "notmuch new", the new default\r
123 > * "" - do nothing\r
124 > * "script" - run script\r
125\r
126 > Regards,\r
127 >   Dmitry\r
128 \r
129 I like it!\r