1 Return-Path: <jani@nikula.org>
\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 5E49A431FB6
\r
6 for <notmuch@notmuchmail.org>; Mon, 4 Jun 2012 00:08:32 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\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 MrtFbJbowH-Q for <notmuch@notmuchmail.org>;
\r
16 Mon, 4 Jun 2012 00:08:30 -0700 (PDT)
\r
17 Received: from mail-vb0-f53.google.com (mail-vb0-f53.google.com
\r
18 [209.85.212.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits))
\r
19 (No client certificate requested)
\r
20 by olra.theworths.org (Postfix) with ESMTPS id 3C4B7431FAF
\r
21 for <notmuch@notmuchmail.org>; Mon, 4 Jun 2012 00:08:30 -0700 (PDT)
\r
22 Received: by vbbfc26 with SMTP id fc26so3922644vbb.26
\r
23 for <notmuch@notmuchmail.org>; Mon, 04 Jun 2012 00:08:29 -0700 (PDT)
\r
24 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
\r
25 d=google.com; s=20120113;
\r
26 h=from:to:subject:in-reply-to:references:user-agent:date:message-id
\r
27 :mime-version:content-type:x-gm-message-state;
\r
28 bh=Mp6IuJtRzw3lg+oMnyGldGAEZSjUe1CJWqaatsOhfHk=;
\r
29 b=LCBbYwdko1j+ltbelyQGrwGERnYP1KhMzMe9yvotJRaaUn3odWR0+Qa0SSxkg1Nyz1
\r
30 dcPAq8vUlazFwyYUF8M/Pe9Rh07ObBwmeXvwGZi0PunEOa6llqxRz4jqU5X3dUd9m+Ei
\r
31 5nQw/rZ2sq9uaQKWt5BTandQ+PHeTgIpqoKXg7zDIz4gVOfMyjCJkZDsNYzc3enSHRt0
\r
32 1Al10+JTFn+2T9GUE2s5xOZ+n1V2r+wAhWb8ShabMSHMg9AxDJC28cbamYhbOXjIhKZ9
\r
33 0VKeXwZ5g3p8i52xLmAh/nHmreBQsdJHbgULnIPHq+G22GDMi5pM4jUz0Kh0UkEGIU4O
\r
35 Received: by 10.220.115.81 with SMTP id h17mr11162796vcq.66.1338793709612;
\r
36 Mon, 04 Jun 2012 00:08:29 -0700 (PDT)
\r
37 Received: from localhost (nikula.org. [92.243.24.172])
\r
38 by mx.google.com with ESMTPS id by3sm16079090vdc.17.2012.06.04.00.08.28
\r
39 (version=SSLv3 cipher=OTHER); Mon, 04 Jun 2012 00:08:29 -0700 (PDT)
\r
40 From: Jani Nikula <jani@nikula.org>
\r
41 To: Austin Clements <amdragon@MIT.EDU>, notmuch@notmuchmail.org
\r
42 Subject: Re: [PATCH 4/4] lib: Treat messages in new/ as maildir messages with
\r
44 In-Reply-To: <1338742656-11640-5-git-send-email-amdragon@mit.edu>
\r
45 References: <1338742656-11640-1-git-send-email-amdragon@mit.edu>
\r
46 <1338742656-11640-5-git-send-email-amdragon@mit.edu>
\r
47 User-Agent: Notmuch/0.13+9~ga1668d0 (http://notmuchmail.org) Emacs/23.1.1
\r
49 Date: Mon, 04 Jun 2012 07:08:26 +0000
\r
50 Message-ID: <87mx4jr1ud.fsf@nikula.org>
\r
52 Content-Type: text/plain; charset=us-ascii
\r
54 ALoCoQmV5I5Ma/uGkDnsRvbN9brByiIbzv7ZyK4Xu5tP6LPoBahH+AuHTUwRr1W/q3KdyhaHCHZy
\r
55 X-BeenThere: notmuch@notmuchmail.org
\r
56 X-Mailman-Version: 2.1.13
\r
58 List-Id: "Use and development of the notmuch mail system."
\r
59 <notmuch.notmuchmail.org>
\r
60 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
61 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
62 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
63 List-Post: <mailto:notmuch@notmuchmail.org>
\r
64 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
65 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
66 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
67 X-List-Received-Date: Mon, 04 Jun 2012 07:08:32 -0000
\r
69 On Sun, 03 Jun 2012, Austin Clements <amdragon@MIT.EDU> wrote:
\r
70 > This fixes the broken test added a few patches ago by synchronizing
\r
71 > the tags of messages in new/, even if they have no "info" part. See
\r
72 > the test patch for rationale.
\r
74 There's no harm in copy-pasting some of the rationale here. It's easier
\r
77 The series LGTM, modulo the commit message nitpicks.
\r
80 > lib/message.cc | 20 +++++++++++++-------
\r
81 > test/maildir-sync | 1 -
\r
82 > 2 files changed, 13 insertions(+), 8 deletions(-)
\r
84 > diff --git a/lib/message.cc b/lib/message.cc
\r
85 > index bbac2ff..978de06 100644
\r
86 > --- a/lib/message.cc
\r
87 > +++ b/lib/message.cc
\r
88 > @@ -1090,13 +1090,19 @@ notmuch_message_maildir_flags_to_tags (notmuch_message_t *message)
\r
91 > flags = strstr (filename, ":2,");
\r
95 > - seen_maildir_info = 1;
\r
98 > - combined_flags = talloc_strdup_append (combined_flags, flags);
\r
100 > + seen_maildir_info = 1;
\r
102 > + combined_flags = talloc_strdup_append (combined_flags, flags);
\r
103 > + } else if (STRNCMP_LITERAL (dir, "new/") == 0) {
\r
104 > + /* Messages are delivered to new/ with no "info" part, but
\r
105 > + * they effectively have default maildir flags. According
\r
106 > + * to the spec, we should ignore the info part for
\r
107 > + * messages in new/, but some MUAs (mutt) can set maildir
\r
108 > + * flags on messages in new/, so we're liberal in what we
\r
110 > + seen_maildir_info = 1;
\r
114 > /* If none of the filenames have any maildir info field (not even
\r
115 > diff --git a/test/maildir-sync b/test/maildir-sync
\r
116 > index 6360fd2..01348d3 100755
\r
117 > --- a/test/maildir-sync
\r
118 > +++ b/test/maildir-sync
\r
119 > @@ -167,7 +167,6 @@ notmuch tag +unread +draft -flagged subject:"Non-compliant maildir info"
\r
120 > test_expect_equal "$(cd $MAIL_DIR/cur/; ls non-compliant*)" "non-compliant-maildir-info:2,These-are-not-flags-in-ASCII-order-donottouch"
\r
122 > test_begin_subtest "Files in new/ get default synchronized tags"
\r
123 > -test_subtest_known_broken
\r
124 > OLDCONFIG=$(notmuch config get new.tags)
\r
125 > notmuch config set new.tags test
\r
126 > add_message [subject]='"File in new/"' [dir]=new [filename]='file-in-new'
\r
130 > _______________________________________________
\r
131 > notmuch mailing list
\r
132 > notmuch@notmuchmail.org
\r
133 > http://notmuchmail.org/mailman/listinfo/notmuch
\r