Re: [PATCH] create .mailmap file (for git shortlog/blame)
[notmuch-archives.git] / fa / 94d41bef9b5651c38dbe6beea337d683a77b4f
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 363B5431FAF\r
6         for <notmuch@notmuchmail.org>; Tue,  3 Jul 2012 15:21:11 -0700 (PDT)\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 IqHR9Nfr+O21 for <notmuch@notmuchmail.org>;\r
16         Tue,  3 Jul 2012 15:21:07 -0700 (PDT)\r
17 Received: from dmz-mailsec-scanner-7.mit.edu (DMZ-MAILSEC-SCANNER-7.MIT.EDU\r
18         [18.7.68.36])\r
19         by olra.theworths.org (Postfix) with ESMTP id 6CB00431FC0\r
20         for <notmuch@notmuchmail.org>; Tue,  3 Jul 2012 15:21:06 -0700 (PDT)\r
21 X-AuditID: 12074424-b7f2a6d0000008bf-50-4ff370518b17\r
22 Received: from mailhub-auth-2.mit.edu ( [18.7.62.36])\r
23         by dmz-mailsec-scanner-7.mit.edu (Symantec Messaging Gateway) with SMTP\r
24         id 4B.F6.02239.15073FF4; Tue,  3 Jul 2012 18:21:05 -0400 (EDT)\r
25 Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103])\r
26         by mailhub-auth-2.mit.edu (8.13.8/8.9.2) with ESMTP id q63ML4mu022243; \r
27         Tue, 3 Jul 2012 18:21:05 -0400\r
28 Received: from drake.dyndns.org (26-4-182.dynamic.csail.mit.edu [18.26.4.182])\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 q63ML1vx023222\r
32         (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT);\r
33         Tue, 3 Jul 2012 18:21:02 -0400 (EDT)\r
34 Received: from amthrax by drake.dyndns.org with local (Exim 4.77)\r
35         (envelope-from <amdragon@mit.edu>)\r
36         id 1SmBSv-0007fS-0y; Tue, 03 Jul 2012 18:21:01 -0400\r
37 From: Austin Clements <amdragon@MIT.EDU>\r
38 To: notmuch@notmuchmail.org\r
39 Subject: [PATCH 4/8] emacs: Helper for reporting search parsing errors\r
40 Date: Tue,  3 Jul 2012 18:20:55 -0400\r
41 Message-Id: <1341354059-29396-5-git-send-email-amdragon@mit.edu>\r
42 X-Mailer: git-send-email 1.7.10\r
43 In-Reply-To: <1341354059-29396-1-git-send-email-amdragon@mit.edu>\r
44 References: <1341354059-29396-1-git-send-email-amdragon@mit.edu>\r
45 X-Brightmail-Tracker:\r
46  H4sIAAAAAAAAA+NgFrrAIsWRmVeSWpSXmKPExsUixG6nohtY8NnfYNpLQ4sje2axWyw985/Z\r
47         4vrNmcwWb1bOY3Vg8dg56y67x+GvC1k8nq26xezR9GMxawBLFJdNSmpOZllqkb5dAlfGzqX/\r
48         WAo6eSr6zk9mbGC8yNnFyMkhIWAiceXIFhYIW0ziwr31bF2MXBxCAvsYJc7dbWYDSQgJrGeU\r
49         aN0rCJE4ySQx4c8hRghnLqPE3G2vWEGq2AQ0JLbtX84IYosISEvsvDsbLM4skCtxtvUwWFxY\r
50         wE3i3uU9TCA2i4CqxMre3UCrOTh4BRwkNnf4QFwhL/H0fh/YYk4BR4kVN8+yQBzhILHtQwfr\r
51         BEb+BYwMqxhlU3KrdHMTM3OKU5N1i5MT8/JSi3TN9XIzS/RSU0o3MYIDzkVlB2PzIaVDjAIc\r
52         jEo8vIkKn/2FWBPLiitzDzFKcjApifJeyQMK8SXlp1RmJBZnxBeV5qQWH2KU4GBWEuFdnQSU\r
53         401JrKxKLcqHSUlzsCiJ815PuekvJJCeWJKanZpakFoEk5Xh4FCS4GUARpaQYFFqempFWmZO\r
54         CUKaiYMTZDgP0PBl+SDDiwsSc4sz0yHypxgVpcR5d4IkBEASGaV5cL2whPCKURzoFWFeRpAV\r
55         PMBkAtf9CmgwE9DgvMWfQAaXJCKkpBoYF8r5inRuWmP5+r+XyCN7tm3vHiub6BQKuP0vVl3S\r
56         ImJyS3XWNMfzNobe6mHrEoJntz3l8d1WKPVfzetyWlXhzvJDv/yP96cnf2Uqjp9iqpH+W/fE\r
57         AXfnXrYT4fUsHubREt6y4k/lRWZK6PUEn+0yaNsz4W2Ro5DH2zux73/r3v7hLrHVj0OJpTgj\r
58         0VCLuag4EQASv9HR4wIAAA==\r
59 Cc: tomi.ollila@iki.fi\r
60 X-BeenThere: notmuch@notmuchmail.org\r
61 X-Mailman-Version: 2.1.13\r
62 Precedence: list\r
63 List-Id: "Use and development of the notmuch mail system."\r
64         <notmuch.notmuchmail.org>\r
65 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
66         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
67 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
68 List-Post: <mailto:notmuch@notmuchmail.org>\r
69 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
70 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
71         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
72 X-List-Received-Date: Tue, 03 Jul 2012 22:21:11 -0000\r
73 \r
74 This removes the last bit of direct output from the parsing function.\r
75 With the parser now responsible solely for parsing, we can swap it out\r
76 for another parser.\r
77 ---\r
78  emacs/notmuch.el |   10 +++++++++-\r
79  1 file changed, 9 insertions(+), 1 deletion(-)\r
80 \r
81 diff --git a/emacs/notmuch.el b/emacs/notmuch.el\r
82 index 4a6490a..a073367 100644\r
83 --- a/emacs/notmuch.el\r
84 +++ b/emacs/notmuch.el\r
85 @@ -745,6 +745,13 @@ non-authors is found, assume that all of the authors match."\r
86         (setq notmuch-search-target-thread "found")\r
87         (goto-char beg)))))\r
88  \r
89 +(defun notmuch-search-show-error (string &rest objects)\r
90 +  (save-excursion\r
91 +    (goto-char (point-max))\r
92 +    (insert "Error: Unexpected output from notmuch search:\n")\r
93 +    (insert (apply #'format string objects))\r
94 +    (insert "\n")))\r
95 +\r
96  (defun notmuch-search-process-filter (proc string)\r
97    "Process and filter the output of \"notmuch search\""\r
98    (let ((buffer (process-buffer proc)))\r
99 @@ -767,7 +774,8 @@ non-authors is found, assume that all of the authors match."\r
100                            (tags (match-string 6 string))\r
101                            (tag-list (if tags (save-match-data (split-string tags)))))\r
102                       (if (/= (match-beginning 1) line)\r
103 -                         (insert (concat "Error: Unexpected output from notmuch search:\n" (substring string line (match-beginning 1)) "\n")))\r
104 +                         (notmuch-search-show-error\r
105 +                          (substring string line (match-beginning 1))))\r
106                       (notmuch-search-show-result thread-id date count authors subject tag-list)\r
107                       (set 'line (match-end 0)))\r
108                   (set 'more nil)\r
109 -- \r
110 1.7.10\r
111 \r