1 Return-Path: <imain@stemwinder.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 10A3E431FBC
\r
6 for <notmuch@notmuchmail.org>; Wed, 1 Oct 2014 12:43:44 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5
\r
12 tests=[RCVD_IN_DNSWL_NONE=-0.0001] 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 OB5eh8ss83iO for <notmuch@notmuchmail.org>;
\r
16 Wed, 1 Oct 2014 12:43:40 -0700 (PDT)
\r
17 Received: from cmta5.telus.net (cmta5.telus.net [209.171.16.78])
\r
18 by olra.theworths.org (Postfix) with ESMTP id AF52B431FB6
\r
19 for <notmuch@notmuchmail.org>; Wed, 1 Oct 2014 12:43:40 -0700 (PDT)
\r
20 Received: from ovo.mains.priv ([207.102.88.62]) by cmta5.telus.net with TELUS
\r
21 id xvje1o00R1LiWEf01vjekt; Wed, 01 Oct 2014 13:43:39 -0600
\r
22 X-Authority-Analysis: v=2.0 cv=JvIvWrEC c=1 sm=2
\r
23 a=EcQDfIwDZEqJA1f7rVUV8Q==:17 a=S-IsBHyFrF4A:10 a=tsa3CZZnAAAA:8
\r
24 a=ANjgZLozyFeyC-GoRkwA:9 a=EcQDfIwDZEqJA1f7rVUV8Q==:117
\r
25 X-Telus-Outbound-IP: 207.102.88.62
\r
26 From: Ian Main <imain@stemwinder.org>
\r
27 To: notmuch@notmuchmail.org
\r
28 Subject: [PATCH] VIM: Add a 'tag all' folder option.
\r
29 Date: Wed, 1 Oct 2014 12:43:33 -0700
\r
30 Message-Id: <1412192613-16552-1-git-send-email-imain@stemwinder.org>
\r
31 X-Mailer: git-send-email 1.9.3
\r
32 X-BeenThere: notmuch@notmuchmail.org
\r
33 X-Mailman-Version: 2.1.13
\r
35 List-Id: "Use and development of the notmuch mail system."
\r
36 <notmuch.notmuchmail.org>
\r
37 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
38 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
39 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
40 List-Post: <mailto:notmuch@notmuchmail.org>
\r
41 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
42 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
43 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
44 X-List-Received-Date: Wed, 01 Oct 2014 19:43:44 -0000
\r
46 This adds the ability to mark an entire folder as read (or any other
\r
47 tags you like once you map it).
\r
51 vim/notmuch.vim | 11 +++++++++++
\r
52 1 file changed, 11 insertions(+)
\r
54 diff --git a/vim/notmuch.vim b/vim/notmuch.vim
\r
55 index 331e930..3f2444b 100644
\r
56 --- a/vim/notmuch.vim
\r
57 +++ b/vim/notmuch.vim
\r
58 @@ -11,6 +11,7 @@ let g:loaded_notmuch = "yep"
\r
59 let g:notmuch_folders_maps = {
\r
60 \ '<Enter>': 'folders_show_search()',
\r
61 \ 's': 'folders_search_prompt()',
\r
62 + \ 'A': 'folders_tag_all("-inbox -unread")',
\r
63 \ '=': 'folders_refresh()',
\r
66 @@ -378,6 +379,16 @@ ruby << EOF
\r
70 +function! s:folders_tag_all(tags)
\r
72 + n = $curbuf.line_number
\r
73 + s = $searches[n - 1]
\r
74 + t = VIM::evaluate('a:tags')
\r
77 + call s:folders_refresh()
\r
80 function! s:folders()
\r
81 call s:new_buffer('folders')
\r
82 ruby folders_render()
\r