1 Return-Path: <felipe.contreras@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 E3C54431FDB
\r
6 for <notmuch@notmuchmail.org>; Sat, 2 Nov 2013 07:03:03 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=-0.799 tagged_above=-999 required=5
\r
12 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,
\r
13 FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled
\r
14 Received: from olra.theworths.org ([127.0.0.1])
\r
15 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
16 with ESMTP id v7rO-hxoAhkU for <notmuch@notmuchmail.org>;
\r
17 Sat, 2 Nov 2013 07:02:59 -0700 (PDT)
\r
18 Received: from mail-ob0-f181.google.com (mail-ob0-f181.google.com
\r
19 [209.85.214.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits))
\r
20 (No client certificate requested)
\r
21 by olra.theworths.org (Postfix) with ESMTPS id 5025F431FD0
\r
22 for <notmuch@notmuchmail.org>; Sat, 2 Nov 2013 07:02:50 -0700 (PDT)
\r
23 Received: by mail-ob0-f181.google.com with SMTP id wp4so5521549obc.26
\r
24 for <notmuch@notmuchmail.org>; Sat, 02 Nov 2013 07:02:49 -0700 (PDT)
\r
25 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
\r
26 h=from:to:cc:subject:date:message-id:in-reply-to:references;
\r
27 bh=1Sgp2+h0xqGl1bwmFSUE0r6eGqS/MhJs59Kv9sxdF9Y=;
\r
28 b=ksE0KstSZAf60rm/Tw0Vm5qkOXqGxiUnhwf1xqT76fUz/8aIMH7Plw/Y+BRTc2vd23
\r
29 BKZE2I/ebUDbYGnPrjj2lQajEkn3krmeOHuvQlJc450d300DI3DmPXQxgofeKC1Ah6dj
\r
30 5e8ru6sDIWXFciwzOIm7bvGSYPHWOLTY1x8V2fgOwWUAC7CgCZMfRuXQXe2/6xPWtEmN
\r
31 YI+CDNEnqeXYDXezHEIylH8XiZRikUHmfLOlMnYW/KK4q+fgvsh/mrBYLqWE6Us8+5Q8
\r
32 m1QSnECynaKPGauORxejd85H+ERL0z790txUEe9YJwFZTMyyMj0V/jt3s7SN1aPYWh9s
\r
34 X-Received: by 10.60.58.166 with SMTP id s6mr6509456oeq.40.1383400969803;
\r
35 Sat, 02 Nov 2013 07:02:49 -0700 (PDT)
\r
36 Received: from localhost (187-162-140-241.static.axtel.net. [187.162.140.241])
\r
37 by mx.google.com with ESMTPSA id
\r
38 z5sm19911864obg.13.2013.11.02.07.02.48 for <multiple recipients>
\r
39 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
\r
40 Sat, 02 Nov 2013 07:02:49 -0700 (PDT)
\r
41 From: Felipe Contreras <felipe.contreras@gmail.com>
\r
42 To: notmuch@notmuchmail.org
\r
43 Subject: [PATCH 05/21] vim: show first message of the thread
\r
44 Date: Sat, 2 Nov 2013 07:55:38 -0600
\r
45 Message-Id: <1383400554-1832-6-git-send-email-felipe.contreras@gmail.com>
\r
46 X-Mailer: git-send-email 1.8.4.2+fc1
\r
47 In-Reply-To: <1383400554-1832-1-git-send-email-felipe.contreras@gmail.com>
\r
48 References: <1383400554-1832-1-git-send-email-felipe.contreras@gmail.com>
\r
49 X-BeenThere: notmuch@notmuchmail.org
\r
50 X-Mailman-Version: 2.1.13
\r
52 List-Id: "Use and development of the notmuch mail system."
\r
53 <notmuch.notmuchmail.org>
\r
54 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
55 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
56 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
57 List-Post: <mailto:notmuch@notmuchmail.org>
\r
58 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
59 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
60 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
61 X-List-Received-Date: Sat, 02 Nov 2013 14:03:04 -0000
\r
63 Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
\r
65 vim/notmuch.vim | 6 ++++--
\r
66 1 file changed, 4 insertions(+), 2 deletions(-)
\r
68 diff --git a/vim/notmuch.vim b/vim/notmuch.vim
\r
69 index 72bf73b..11ea4fd 100644
\r
70 --- a/vim/notmuch.vim
\r
71 +++ b/vim/notmuch.vim
\r
72 @@ -557,6 +557,7 @@ ruby << EOF
\r
73 def search_render(search)
\r
74 date_fmt = VIM::evaluate('g:notmuch_rb_date_format')
\r
75 q = $curbuf.query(search)
\r
76 + q.sort = Notmuch::SORT_NEWEST_FIRST
\r
78 t = q.search_threads
\r
80 @@ -564,10 +565,11 @@ ruby << EOF
\r
82 authors = e.authors.to_utf8.split(/[,|]/).map { |a| author_filter(a) }.join(",")
\r
83 date = Time.at(e.newest_date).strftime(date_fmt)
\r
84 + subject = e.messages.first['subject']
\r
86 - subject = Mail::Field.new("Subject: " + e.subject).to_s
\r
87 + subject = Mail::Field.new("Subject: " + subject).to_s
\r
89 - subject = e.subject.force_encoding('utf-8')
\r
90 + subject = subject.force_encoding('utf-8')
\r
92 b << "%-12s %3s %-20.20s | %s (%s)" % [date, e.matched_messages, authors, subject, e.tags]
\r
93 $threads << e.thread_id
\r