Re: [PATCH 1/3] emacs: add no-display arg to notmuch-hello-refresh-hook
authorJani Nikula <jani@nikula.org>
Tue, 10 Jul 2012 05:10:09 +0000 (08:10 +0300)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:48:07 +0000 (09:48 -0800)
41/73d8bf2c218bee05a4a7adf72409673c55a9c9 [new file with mode: 0644]

diff --git a/41/73d8bf2c218bee05a4a7adf72409673c55a9c9 b/41/73d8bf2c218bee05a4a7adf72409673c55a9c9
new file mode 100644 (file)
index 0000000..8c4aa40
--- /dev/null
@@ -0,0 +1,145 @@
+Return-Path: <jani@nikula.org>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 3E9CA431E64\r
+       for <notmuch@notmuchmail.org>; Mon,  9 Jul 2012 22:10:11 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.699\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.699 tagged_above=-999 required=5\r
+       tests=[HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id DaPdwjlbrO8V for <notmuch@notmuchmail.org>;\r
+       Mon,  9 Jul 2012 22:10:10 -0700 (PDT)\r
+Received: from mail-ob0-f181.google.com (mail-ob0-f181.google.com\r
+       [209.85.214.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id 84D1E431FBF\r
+       for <notmuch@notmuchmail.org>; Mon,  9 Jul 2012 22:10:10 -0700 (PDT)\r
+Received: by obbup19 with SMTP id up19so17448987obb.26\r
+       for <notmuch@notmuchmail.org>; Mon, 09 Jul 2012 22:10:10 -0700 (PDT)\r
+X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;\r
+       d=google.com; s=20120113;\r
+       h=mime-version:in-reply-to:references:date:message-id:subject:from:to\r
+       :cc:content-type:x-gm-message-state;\r
+       bh=Fg2Uwhh5zA8nEdMi2pcJI2a18tVrMZvYYmn8oBVGHnM=;\r
+       b=CLzFdsI/6mzwIOdahpHC3Nru60PSAuB4eqi+GZogwO9HPQe70z3Zl+9Be+TFZIECab\r
+       KLGdxvghbmewMZ3Oo/EABeWwTqSyHvx8udJv65d4WdgNeM7Bdf56Sf0S/bNmphoKkXh4\r
+       LNUUlwXGlfWkAWVOQCozvYHUKu3NJDu/GGr8Mj2NEbNHXV1gtghmLeoyifwgmnWWdKGG\r
+       gv3IXsEG/PmWxsCwm4WDBeQ7t6SHzVxEbIh3dbqnDGFR/P7HXi/iM5c4wURodkOgIJ6T\r
+       9GlRj0YUEWrIG2TpeELAWXcqJOx/uD1xeRj+7aIopOvNGxHq7RP+FoalmOKYydJUNAIo\r
+       vJzw==\r
+MIME-Version: 1.0\r
+Received: by 10.60.29.169 with SMTP id l9mr45156010oeh.14.1341897009938; Mon,\r
+       09 Jul 2012 22:10:09 -0700 (PDT)\r
+Received: by 10.76.10.102 with HTTP; Mon, 9 Jul 2012 22:10:09 -0700 (PDT)\r
+Received: by 10.76.10.102 with HTTP; Mon, 9 Jul 2012 22:10:09 -0700 (PDT)\r
+In-Reply-To: <20120710014946.GB7332@mit.edu>\r
+References:\r
+ <37899e28dbf67e4620a53279a869be3174c02d6f.1339775602.git.jani@nikula.org>\r
+       <20120710014946.GB7332@mit.edu>\r
+Date: Tue, 10 Jul 2012 08:10:09 +0300\r
+Message-ID:\r
+ <CAB+hUn8W_x_BNbzmWuyzReX-oaP67OK0t8y-yNZ5cKfRNdwOmg@mail.gmail.com>\r
+Subject: Re: [PATCH 1/3] emacs: add no-display arg to\r
+       notmuch-hello-refresh-hook\r
+From: Jani Nikula <jani@nikula.org>\r
+To: Austin Clements <amdragon@mit.edu>\r
+Content-Type: multipart/alternative; boundary=e89a8ff256669a3fba04c472beb9\r
+X-Gm-Message-State:\r
+ ALoCoQn99NemvpcM0NwaszaY+zElx/HEYIgy/U6R0zI6Qxi4q4+Cy98ageesncHD47kcMsYveDRn\r
+Cc: notmuch@notmuchmail.org\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Tue, 10 Jul 2012 05:10:11 -0000\r
+\r
+--e89a8ff256669a3fba04c472beb9\r
+Content-Type: text/plain; charset=UTF-8\r
+\r
+On Jul 10, 2012 4:49 AM, "Austin Clements" <amdragon@mit.edu> wrote:\r
+>\r
+> Quoth Jani Nikula on Jun 15 at  6:53 pm:\r
+> > Add no-display arg to notmuch-hello-refresh-hook to allow each hook to\r
+> > decide what is appropriate when no-display is t, which is typically\r
+> > the case when called non-interactively. This is used by the following\r
+> > patch.\r
+> >\r
+> > This breaks existing hooks people might have, which will now need to\r
+> > accept the argument.\r
+> >\r
+> > Signed-off-by: Jani Nikula <jani@nikula.org>\r
+>\r
+> This seems like an overloaded use of no-display.  If I'm reading the\r
+> code right, no-display indicates whether or not the notmuch-hello\r
+> buffer should be switched to and seems like a workaround for some\r
+> particular corner-case (I'm not even sure what).  This seems like a\r
+> strange condition to predicate a hook on (but maybe I just don't\r
+> understand).  What condition, abstractly speaking, is\r
+> notmuch-hello-refresh-status-message trying to run under?\r
+\r
+IIUC, no-display is useful for calling refresh from outside of emacs, e.g.\r
+from post-new hook in an automated fashion, so you can have an up-to-date\r
+buffer when you switch to it. There's no point in displaying the refresh\r
+message when you don't also switch to the buffer, is there? And this way\r
+you'll get the diff between the manual (through user interaction) refreshes\r
+of the buffer, not between two cron jobs.\r
+\r
+J.\r
+\r
+--e89a8ff256669a3fba04c472beb9\r
+Content-Type: text/html; charset=UTF-8\r
+Content-Transfer-Encoding: quoted-printable\r
+\r
+<p><br>\r
+On Jul 10, 2012 4:49 AM, &quot;Austin Clements&quot; &lt;<a href=3D"mailto:=\r
+amdragon@mit.edu">amdragon@mit.edu</a>&gt; wrote:<br>\r
+&gt;<br>\r
+&gt; Quoth Jani Nikula on Jun 15 at =C2=A06:53 pm:<br>\r
+&gt; &gt; Add no-display arg to notmuch-hello-refresh-hook to allow each ho=\r
+ok to<br>\r
+&gt; &gt; decide what is appropriate when no-display is t, which is typical=\r
+ly<br>\r
+&gt; &gt; the case when called non-interactively. This is used by the follo=\r
+wing<br>\r
+&gt; &gt; patch.<br>\r
+&gt; &gt;<br>\r
+&gt; &gt; This breaks existing hooks people might have, which will now need=\r
+ to<br>\r
+&gt; &gt; accept the argument.<br>\r
+&gt; &gt;<br>\r
+&gt; &gt; Signed-off-by: Jani Nikula &lt;<a href=3D"mailto:jani@nikula.org"=\r
+>jani@nikula.org</a>&gt;<br>\r
+&gt;<br>\r
+&gt; This seems like an overloaded use of no-display. =C2=A0If I&#39;m read=\r
+ing the<br>\r
+&gt; code right, no-display indicates whether or not the notmuch-hello<br>\r
+&gt; buffer should be switched to and seems like a workaround for some<br>\r
+&gt; particular corner-case (I&#39;m not even sure what). =C2=A0This seems =\r
+like a<br>\r
+&gt; strange condition to predicate a hook on (but maybe I just don&#39;t<b=\r
+r>\r
+&gt; understand). =C2=A0What condition, abstractly speaking, is<br>\r
+&gt; notmuch-hello-refresh-status-message trying to run under?</p>\r
+<p>IIUC, no-display is useful for calling refresh from outside of emacs, e.=\r
+g. from post-new hook in an automated fashion, so you can have an up-to-dat=\r
+e buffer when you switch to it. There&#39;s no point in displaying the refr=\r
+esh message when you don&#39;t also switch to the buffer, is there? And thi=\r
+s way you&#39;ll get the diff between the manual (through user interaction)=\r
+ refreshes of the buffer, not between two cron jobs.</p>\r
+\r
+<p>J.</p>\r
+\r
+--e89a8ff256669a3fba04c472beb9--\r