Re: [PATCH v3 02/13] util: Const version of strtok_len
[notmuch-archives.git] / 44 / 694bc8758a623eecfa8356eb19052201334fe4
1 Return-Path: <ccx@webprojekty.cz>\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 BEA20429E42\r
6         for <notmuch@notmuchmail.org>; Tue,  3 Jan 2012 15:34:19 -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: 0\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
12         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 32ylr5vV8Y2A for <notmuch@notmuchmail.org>;\r
16         Tue,  3 Jan 2012 15:34:18 -0800 (PST)\r
17 X-Greylist: delayed 342 seconds by postgrey-1.32 at olra;\r
18         Tue, 03 Jan 2012 15:34:18 PST\r
19 Received: from new.webprojekty.cz (new.webprojekty.cz [178.238.36.76])\r
20         by olra.theworths.org (Postfix) with ESMTP id 13328431FD0\r
21         for <notmuch@notmuchmail.org>; Tue,  3 Jan 2012 15:34:18 -0800 (PST)\r
22 Received: from eee.ccx (156.200.broadband11.iol.cz [90.178.200.156])\r
23         (Authenticated sender: ccx@webprojekty.cz)\r
24         by new.webprojekty.cz (Postfix) with ESMTPSA id BDD4C800405\r
25         for <notmuch@notmuchmail.org>; Wed,  4 Jan 2012 00:28:34 +0100 (CET)\r
26 Date: Wed, 4 Jan 2012 00:31:30 +0100\r
27 From: Jan Pobrislo <ccx@webprojekty.cz>\r
28 To: notmuch@notmuchmail.org\r
29 Subject: Re: [ANNOUNCE] mutt with notmuch support\r
30 Message-ID: <20120104003130.409e979f@eee.ccx>\r
31 In-Reply-To: <20120103123938.GA15106@x2.net.home>\r
32 References: <20120103123938.GA15106@x2.net.home>\r
33 X-Mailer: Claws Mail 3.7.9 (GTK+ 2.24.5; i686-pc-linux-gnu)\r
34 Mime-Version: 1.0\r
35 Content-Type: text/plain; charset=US-ASCII\r
36 Content-Transfer-Encoding: 7bit\r
37 X-BeenThere: notmuch@notmuchmail.org\r
38 X-Mailman-Version: 2.1.13\r
39 Precedence: list\r
40 List-Id: "Use and development of the notmuch mail system."\r
41         <notmuch.notmuchmail.org>\r
42 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
43         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
44 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
45 List-Post: <mailto:notmuch@notmuchmail.org>\r
46 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
47 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
48         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
49 X-List-Received-Date: Tue, 03 Jan 2012 23:34:20 -0000\r
50 \r
51 On Tue, 3 Jan 2012 13:39:38 +0100\r
52 Karel Zak <kzak@redhat.com> wrote:\r
53 \r
54\r
55 > This is not another curses front-end for notmuch, this is mutt :-)\r
56\r
57 > I have forked mutt to seriously integrate notmuch to this excellent\r
58 > e-mail client. I don't want to use symlinks or any other hacks to\r
59 > emulate virtual folders. My wish is mutt linked with libnotmuch.\r
60 \r
61 Good to hear!\r
62 \r
63 First, I'll shamelessly plug in my set of scripts that do the dirty work by\r
64 using symlinked maildirs to interact with any maildir capable mail reader.\r
65 It's mainly intended to be interface from shell, calling out to mutt or any\r
66 mail reader only when necessary, so it's somewhat reverse paradigm to yours.\r
67 \r
68 view @ http://webprojekty.cz/ccx/loggerhead/zmuch/files\r
69 bzr branch http://webprojekty.cz/ccx/bzr/zmuch\r
70 \r
71 Sadly I had to take hiatus mid-rewrite of it, but several interesting points\r
72 came up when I was talking about it with cworth and others.\r
73 \r
74 We agreed that we wanted to standardize several features currently present in\r
75 emacs UI, so we can share configuration among several implementations. Most\r
76 important of these were:\r
77 \r
78 saved searches\r
79 --------------\r
80 \r
81 This is the feature I started writing my scripts for. I wanted to refer by a\r
82 simple shorthand to complex queries. I know emacs UI has some notion of\r
83 remembered queries, but I haven't really bothered trying it out. I assume you\r
84 will want to represent these as separate mailboxes, maybe shown using the\r
85 sidebar patch, so one has quick overview what's new in which ML.\r
86 \r
87 The way I do this is that command:\r
88 \r
89 $ zmuch search :foss and not :notmuch\r
90 \r
91 will expand to:\r
92 \r
93 $ notmuch search ( to:lists.xmms.se or ( to:cairo-announce@cairographics.org\r
94     or to:cairo@cairographics.org ) or ( to:notmuch@notmuchmail.org or\r
95         to:notmuch-request@notmuchmail.org ) ) and not (\r
96         to:notmuch@notmuchmail.org or to:notmuch-request@notmuchmail.org )\r
97 \r
98 Which would be bit too much to type by hand, even for so few lists.\r
99 This would be using .notmuch-config with something like this:\r
100 \r
101 [zmuch_searches]\r
102 xmms2=to:lists.xmms.se\r
103 cairo=to:cairo-announce@cairographics.org or to:cairo@cairographics.org\r
104 foss=:xmms2 or :cairo or :notmuch\r
105 \r
106 Subset of this issue is the question: How to display overview of such saved\r
107 queries in a sensible manner? Mutt probably can't go beyond unread/total\r
108 number of messages for each query and that's actually what I have currently\r
109 implemented. Given the config:\r
110 \r
111 [interesting]\r
112 query=is:unread and not ( is:spam or is:mute )\r
113 \r
114 [zmuch_show]\r
115 selected=twisted;notmuch;gentoo-cs;cajovna;system;inbox\r
116 \r
117 it would show number of interesting/total messages for each of the listed\r
118 saved query. Much nicer generalisation was then discussed on IRC, where you\r
119 could use regular saved search instead of separate [interesting] entry,\r
120 allowing you to have several such queries, eg. for displaying\r
121 unread/flagged/muted/total or anything your heart desires.\r
122 \r
123 way to call notmuch\r
124 -------------------\r
125 \r
126 This might be feature you'll be probably missing due to using libnotmuch\r
127 directly instead of calling out executable as emacs UI does, but I find it\r
128 really useful to be able to layer functionality unix-style. Not only you can\r
129 run remote notmuch via ssh, but also my saved search implementation does this\r
130 by expanding arguments passed to the notmuch executable and as such is usable\r
131 from any UI that has configurable executable to call instead of "notmuch".\r
132 \r
133 colors\r
134 ------\r
135 \r
136 Again dunno how much this applies to mutt, as it has it's own coloring\r
137 paradigm, but I find it neat to be able to do something like this globally:\r
138 \r
139 [tag_colors]\r
140 flagged=%F{red}\r
141 mute=%B%F{black}\r
142 spam=%F{magenta}\r
143 unread=%F{cyan}\r
144 replied=%F{yellow}\r
145 sent=%F{green}\r
146 attachment=%B\r
147 \r
148 This is syntax that zsh uses for it's print/prompt formatting and is obviously\r
149 ANSI VT specific (%B is for bold/standout). GUI lovers will probably want #RGB\r
150 scheme too.\r
151 \r
152 \r
153 HTH bring up some good ideas and discussion.\r