From: Austin Clements Date: Tue, 21 Feb 2012 05:59:20 +0000 (+1900) Subject: Re: [PATCH v5.2 7/7] emacs: Use the new JSON reply format and message-cite-original X-Git-Url: http://git.tremily.us/gitweb.cgi?a=commitdiff_plain;h=98d0fb6f1d555600bd664562737952bcaaa87463;p=notmuch-archives.git Re: [PATCH v5.2 7/7] emacs: Use the new JSON reply format and message-cite-original --- diff --git a/8c/80e3ac7e09b4e62265e6118bbd2c6e62484853 b/8c/80e3ac7e09b4e62265e6118bbd2c6e62484853 new file mode 100644 index 000000000..af004bed7 --- /dev/null +++ b/8c/80e3ac7e09b4e62265e6118bbd2c6e62484853 @@ -0,0 +1,117 @@ +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 3C066431FAF + for ; Mon, 20 Feb 2012 21:59:24 -0800 (PST) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: -0.7 +X-Spam-Level: +X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 + tests=[RCVD_IN_DNSWL_LOW=-0.7] 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 8CgtjXtMHxST for ; + Mon, 20 Feb 2012 21:59:23 -0800 (PST) +Received: from dmz-mailsec-scanner-5.mit.edu (DMZ-MAILSEC-SCANNER-5.MIT.EDU + [18.7.68.34]) + by olra.theworths.org (Postfix) with ESMTP id 929DC431FAE + for ; Mon, 20 Feb 2012 21:59:23 -0800 (PST) +X-AuditID: 12074422-b7fd66d0000008f9-de-4f4332badb61 +Received: from mailhub-auth-1.mit.edu ( [18.9.21.35]) + by dmz-mailsec-scanner-5.mit.edu (Symantec Messaging Gateway) with SMTP + id 2F.17.02297.AB2334F4; Tue, 21 Feb 2012 00:59:23 -0500 (EST) +Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103]) + by mailhub-auth-1.mit.edu (8.13.8/8.9.2) with ESMTP id q1L5xMQx027803; + Tue, 21 Feb 2012 00:59:22 -0500 +Received: from awakening.csail.mit.edu (awakening.csail.mit.edu [18.26.4.91]) + (authenticated bits=0) + (User authenticated as amdragon@ATHENA.MIT.EDU) + by outgoing.mit.edu (8.13.6/8.12.4) with ESMTP id q1L5xKev014435 + (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT); + Tue, 21 Feb 2012 00:59:21 -0500 (EST) +Received: from amthrax by awakening.csail.mit.edu with local (Exim 4.77) + (envelope-from ) + id 1Rziky-0001bB-LG; Tue, 21 Feb 2012 00:59:20 -0500 +Date: Tue, 21 Feb 2012 00:59:20 -0500 +From: Austin Clements +To: Adam Wolfe Gordon +Subject: Re: [PATCH v5.2 7/7] emacs: Use the new JSON reply format and + message-cite-original +Message-ID: <20120221055920.GA30513@mit.edu> +References: <1329361957-28493-1-git-send-email-awg+notmuch@xvx.ca> + <1329361957-28493-8-git-send-email-awg+notmuch@xvx.ca> +MIME-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +Content-Disposition: inline +In-Reply-To: <1329361957-28493-8-git-send-email-awg+notmuch@xvx.ca> +User-Agent: Mutt/1.5.21 (2010-09-15) +X-Brightmail-Tracker: + H4sIAAAAAAAAA+NgFmpmleLIzCtJLcpLzFFi42IR4hRV1t1t5OxvMOUMk8WRPbPYLa7fnMns + wOTxbNUtZo+mH4tZA5iiuGxSUnMyy1KL9O0SuDI+zVjDUrBOoGLnwscsDYwzeLsYOTkkBEwk + 2pdOZIWwxSQu3FvP1sXIxSEksI9R4uiPblYIZwOjxJsJX5lBqoQETjJJvL/gB5FYwijxpO0I + WDuLgKpE64597CA2m4CGxLb9yxlBbBEBLYkf67+C1TALSEt8+93MBGILC8RJfPt+BayeV0BH + YtGemawQC6olJvefYYaIC0qcnPmEBaJXS+LGv5dAvRxgc5b/4wAJcwo4SzS9+A22SlRARWLK + yW1sExiFZiHpnoWkexZC9wJG5lWMsim5Vbq5iZk5xanJusXJiXl5qUW6pnq5mSV6qSmlmxhB + Yc3uorSD8edBpUOMAhyMSjy8nKVO/kKsiWXFlbmHGCU5mJREeVcYOPsL8SXlp1RmJBZnxBeV + 5qQWH2KU4GBWEuHdpAmU401JrKxKLcqHSUlzsCiJ86prvfMTEkhPLEnNTk0tSC2CycpwcChJ + 8JoC41dIsCg1PbUiLTOnBCHNxMEJMpwHaLg6SA1vcUFibnFmOkT+FKOilDhEQgAkkVGaB9cL + SzuvGMWBXhHmNQSp4gGmLLjuV0CDmYAGt/x3BBlckoiQkmpgLLrA2cNf1Pb/qWfop2oPqZza + 8M8dras2rgu0kO5fLX7qJftPZ5WjGiUikrZsXVOMt6dpFWWUf76y/afZjVvXWPo7zb/ybtq4 + 50v2hfLCevv5s/u6szl23Rdg+yb02jpuq1Ou/tv0NRY3bpVUL6+zdJEs+SoqvifmJvOE0z6V + uZOZ2mdH7VilxFKckWioxVxUnAgAdhFT5hYDAAA= +Cc: notmuch@notmuchmail.org +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, 21 Feb 2012 05:59:24 -0000 + +Quoth Adam Wolfe Gordon on Feb 15 at 8:12 pm: +> Use the new JSON reply format to create replies in emacs. Quote HTML +> parts nicely by using mm-display-part to turn them into displayable +> text, then quoting them with message-cite-original. This is very +> useful for users who regularly receive HTML-only email. +> +> Use message-mode's message-cite-original function to create the +> quoted body for reply messages. In order to make this act like the +> existing notmuch defaults, you will need to set the following in +> your emacs configuration: +> +> message-citation-line-format "On %a, %d %b %Y, %f wrote:" +> message-citation-line-function 'message-insert-formatted-citation-line + +I've been thinking about this more. message-mode's default citation +line is really unfortunate and quite possibly insane ("writes" isn't +even the right tense and what's up with that extra line break?). The +option to change this is also well hidden (as an experiment, I tried +navigating to it through customize and couldn't figure out where it +was, even though I knew what I was looking for). In general, I'm a +fan of inheriting as many options from Emacs as possible, but people +*are* going to ask how to change this and the default setting *is* +going to turn people off of notmuch ("What mail client do you use that +generates those quirky citation lines?" "I use notmuch!" "Is that, +like, from the 80's?"). + +So, what about adding a notmuch customize option for selecting the +citation line format? It could offer a few const choices, including a +default, sane format, plus the option to enter your own or to fall +back to whatever message-mode is configured to do. If we do this, +it's probably best done in a follow-up series, but this seemed like an +appropriate place to bring it up. + +> The tests have been updated to reflect the (ugly) emacs default. +> --- +> emacs/notmuch-lib.el | 6 ++ +> emacs/notmuch-mua.el | 127 +++++++++++++++++++++++++++++++++++--------------- +> test/emacs | 8 ++-- +> 3 files changed, 100 insertions(+), 41 deletions(-)