Re: [PATCH] emacs: wash: make word-wrap bound message width
[notmuch-archives.git] / f6 / 0f1ee28d43a271b38f7cc5fa8d7dd342db5767
1 Return-Path: <markwalters1009@gmail.com>\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 906C1431FAF\r
6         for <notmuch@notmuchmail.org>; Sat, 24 Nov 2012 05:21:03 -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: 2.7\r
10 X-Spam-Level: **\r
11 X-Spam-Status: No, score=2.7 tagged_above=-999 required=5\r
12         tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
13         FREEMAIL_ENVFROM_END_DIGIT=1, FREEMAIL_FROM=0.001,\r
14         FREEMAIL_REPLY=2.499, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
15 Received: from olra.theworths.org ([127.0.0.1])\r
16         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
17         with ESMTP id ggEG39vUGR-b for <notmuch@notmuchmail.org>;\r
18         Sat, 24 Nov 2012 05:21:03 -0800 (PST)\r
19 Received: from mail-wi0-f175.google.com (mail-wi0-f175.google.com\r
20         [209.85.212.175]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
21         (No client certificate requested)\r
22         by olra.theworths.org (Postfix) with ESMTPS id E7471431FAE\r
23         for <notmuch@notmuchmail.org>; Sat, 24 Nov 2012 05:21:02 -0800 (PST)\r
24 Received: by mail-wi0-f175.google.com with SMTP id hm11so1793227wib.2\r
25         for <notmuch@notmuchmail.org>; Sat, 24 Nov 2012 05:21:00 -0800 (PST)\r
26 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;\r
27         h=from:to:cc:subject:date:message-id:x-mailer;\r
28         bh=86OJ6ItwwSjti3twsXRw+ydILRsUSjRmZO8Ea29Gl+w=;\r
29         b=hgP+hD5i+Irb6HCRNQzIkytnUg5b8iKPfBarhg0SlLhabWCUyf/28FStnhXyUtsTHH\r
30         +BrgzKtDtZjwWaB7BepkOkpV0tAFq7knYR0KQcih1AcmR/bWwmo9L/IUlYhvWbmUxGp1\r
31         EN4KVI8RIkQeFNQJ9aConIozwraHTMB2MxSCPpvyXsupx/XRE+y8wO+vS2mVGA8nt73M\r
32         QdkbUyGnSlaBc47AQt39bMQJl1OeLM6WT4Q6GkbO28WaBxVyT3RvhG0I0VMdXU1h0mps\r
33         ZLSFpu4xKToRFhSEU8MCElv9WTBISZDakuYAFbXFPqAj6C7XClE9CzGo9FhPdXbIQstQ\r
34         hhTQ==\r
35 Received: by 10.180.14.162 with SMTP id q2mr13659794wic.21.1353763260361;\r
36         Sat, 24 Nov 2012 05:21:00 -0800 (PST)\r
37 Received: from localhost (93-97-24-31.zone5.bethere.co.uk. [93.97.24.31])\r
38         by mx.google.com with ESMTPS id i2sm12682341wiw.3.2012.11.24.05.20.58\r
39         (version=TLSv1/SSLv3 cipher=OTHER);\r
40         Sat, 24 Nov 2012 05:20:59 -0800 (PST)\r
41 From: markwalters1009 <markwalters1009@gmail.com>\r
42 To: notmuch@notmuchmail.org\r
43 Subject: [PATCH v2 0/7] Fix emacs tagging race\r
44 Date: Sat, 24 Nov 2012 13:20:49 +0000\r
45 Message-Id: <1353763256-32336-1-git-send-email-markwalters1009@gmail.com>\r
46 X-Mailer: git-send-email 1.7.9.1\r
47 X-BeenThere: notmuch@notmuchmail.org\r
48 X-Mailman-Version: 2.1.13\r
49 Precedence: list\r
50 List-Id: "Use and development of the notmuch mail system."\r
51         <notmuch.notmuchmail.org>\r
52 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
53         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
54 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
55 List-Post: <mailto:notmuch@notmuchmail.org>\r
56 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
57 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
58         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
59 X-List-Received-Date: Sat, 24 Nov 2012 13:21:03 -0000\r
60 \r
61 This is version 2 of this series: version 1 is at\r
62 id:1352487491-31512-1-git-send-email-markwalters1009@gmail.com but\r
63 this is a much more complete version. Version 1 roughly corresponds to\r
64 patches 5-7.\r
65 \r
66 The first two patches allows queries to come from stdin (if the query\r
67 string is "-"). This is necessary to avoid ARGMAX limits in some\r
68 cases. They are independent of the rest of the series. The main thing\r
69 needed for these two (apart from review!) is a manpage but I wasn't\r
70 sure whether that should go in notmuch-search-terms or somewhere else.\r
71 \r
72 Patches 3 and 4 make the emacs interface use this new functionality to\r
73 pass the tagging query. These two patches depend on the previous two\r
74 but are independent of the later patches. Note that it is possible (if\r
75 unlikely) to trigger the ARGMAX problem in current notmuch: highlight\r
76 most or all of a large search buffer and then try to tag the region.\r
77 \r
78 Patches 5-7 actually fix the race. They do this by appending two query\r
79 strings to each search: one query string for the matching messages and\r
80 one for the non-matching messages. The front-end can then combine\r
81 these query strings to make sure it only tags messages that were\r
82 present/matched when the search buffer was created.\r
83 \r
84 The main changes from v1 are to append query-string rather than all\r
85 the message-ids (so if we had a better way of constructing the queries\r
86 we could switch to that later) and to use Austin's suggestion of\r
87 --queries=true to add the queries. I think we do want the choice as\r
88 appending the string could easily double the size of the output.\r
89 \r
90 This version (since rebasing and tidying) is not heavily tested (all\r
91 tests pass) but I have been running a similar version for some time\r
92 without problems.\r
93 \r
94 Best wishes\r
95 \r
96 Mark\r
97 \r
98 \r
99 \r
100 \r
101 Mark Walters (7):\r
102   cli: allow query to come from stdin\r
103   test: for the new query from stdin functionality\r
104   emacs: notmuch.el split call-process into call-process-region\r
105   emacs: make emacs tagging use the stdin query functionality\r
106   test: test for race when tagging from emacs search\r
107   cli: allow search mode to include msg-ids with JSON output\r
108   emacs: make emacs use message-ids for tagging\r
109 \r
110  emacs/notmuch-tag.el |   14 +++++---\r
111  emacs/notmuch.el     |   47 ++++++++++++++++++++----\r
112  notmuch-search.c     |   95 ++++++++++++++++++++++++++++++++++++++++++++++---\r
113  query-string.c       |   41 +++++++++++++++++++++\r
114  test/emacs           |   21 +++++++++++\r
115  test/tagging         |    9 +++++\r
116  6 files changed, 208 insertions(+), 19 deletions(-)\r
117 \r
118 -- \r
119 1.7.9.1\r
120 \r