Re: [PATCH 0/4] Allow specifying alternate names for addresses in other_email
[notmuch-archives.git] / 65 / 82d517640d8a429c03319943396df34dbe520c
1 Return-Path: <Rainer@krugs.de>\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 5136B431FB6\r
6         for <notmuch@notmuchmail.org>; Sat,  8 Dec 2012 04:40:21 -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.001\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0.001 tagged_above=-999 required=5\r
12         tests=[HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001]\r
13         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 Ni5-M8GuNiKW for <notmuch@notmuchmail.org>;\r
17         Sat,  8 Dec 2012 04:40:20 -0800 (PST)\r
18 Received: from moutng.kundenserver.de (moutng.kundenserver.de\r
19         [212.227.126.187]) (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 19E76431FAE\r
22         for <notmuch@notmuchmail.org>; Sat,  8 Dec 2012 04:40:20 -0800 (PST)\r
23 Received: from mail-lb0-f181.google.com (mail-lb0-f181.google.com\r
24         [209.85.217.181])\r
25         by mrelayeu.kundenserver.de (node=mrbap3) with ESMTP (Nemesis)\r
26         id 0M731J-1Svvfz2JAj-00xMmv; Sat, 08 Dec 2012 13:40:18 +0100\r
27 Received: by mail-lb0-f181.google.com with SMTP id ge1so1091641lbb.26\r
28         for <notmuch@notmuchmail.org>; Sat, 08 Dec 2012 04:40:18 -0800 (PST)\r
29 MIME-Version: 1.0\r
30 Received: by 10.152.46.161 with SMTP id w1mr8297570lam.27.1354970417805; Sat,\r
31         08 Dec 2012 04:40:17 -0800 (PST)\r
32 Received: by 10.112.108.7 with HTTP; Sat, 8 Dec 2012 04:40:17 -0800 (PST)\r
33 In-Reply-To:\r
34  <CAHmME9qSS4RRcrFi_ebPB8Qkx8KtoaJCGXdQ-JLoYygJVMVA2Q@mail.gmail.com>\r
35 References:\r
36  <CAHmME9om0twqigr0L2pwXtbj4ceBVVFz0HqxkwFfB-AnusP2VQ@mail.gmail.com>\r
37         <50c16b03.47e2440a.6038.ffffedce@mx.google.com> <50C1AEA0.9090508@gmail.com>\r
38         <CAHmME9pKBJ1Brad=Z1pErSjGqjsZ8Xn56uM-k-U7WLgwjspN_w@mail.gmail.com>\r
39         <50C1F5C3.6010201@gmail.com>\r
40         <CAHmME9qSS4RRcrFi_ebPB8Qkx8KtoaJCGXdQ-JLoYygJVMVA2Q@mail.gmail.com>\r
41 Date: Sat, 8 Dec 2012 13:40:17 +0100\r
42 Message-ID:\r
43  <CAGhLh6GKRYNxm3=RhZdMwhSc-jDwGgFRrKSQqbagzv=GeH0+Yw@mail.gmail.com>\r
44 Subject: Re: gmail importer script\r
45 From: Rainer M Krug <Rainer@krugs.de>\r
46 To: "Jason A. Donenfeld" <Jason@zx2c4.com>\r
47 Content-Type: multipart/alternative; boundary=bcaec55408906f390304d056a254\r
48 X-Provags-ID: V02:K0:LEXdKncTpzqHMJ/7eCW2QQ25Ti8TD7pQFo5Z4NuM8eX\r
49         4jydoQyBG3iZWllTg3tCCQOktsX10VvIXiUFThW/ujt5/tu4k6\r
50         B6SVQb98nByWQEPl+3hwKbEu41BcHNVH9LOabMxeMSkv0U/0B3\r
51         0xdaUcjgSfSB0cGLxc8NzObs85mnTvwQV+DGX0VMXIco65/Cdx\r
52         NpMaoTfHGlrBP680wMqqcCBqHEMT4x0XGsParlMMAO0EPPY6Ht\r
53         dXE1lY6cB39WF2kx1OPnCX8TDpfd9wT4UHkHMeHKAVJzCXEsrB\r
54         mmlXnNFsJvxxIZDaSlCt1vycjm8zKx96zmKhgweuI07splMyjp\r
55         4DDH0Wm3uVx/uh2QA85oQe+zEshiun6RVatY4UMFL90ArMusDa\r
56         T+cj8KFXvvl0WA0jPBwMQZXEDbbYDrwZ5vaQ5aOHhum7vTY/Pp 3M4QA\r
57 X-Mailman-Approved-At: Mon, 10 Dec 2012 21:54:39 -0800\r
58 Cc: public-notmuch-gxuj+Tv9EO5zyzON3hdc1g@plane.gmane.org,\r
59         notmuch@notmuchmail.org\r
60 X-BeenThere: notmuch@notmuchmail.org\r
61 X-Mailman-Version: 2.1.13\r
62 Precedence: list\r
63 Reply-To: Rainer@krugs.de\r
64 List-Id: "Use and development of the notmuch mail system."\r
65         <notmuch.notmuchmail.org>\r
66 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
67         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
68 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
69 List-Post: <mailto:notmuch@notmuchmail.org>\r
70 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
71 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
72         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
73 X-List-Received-Date: Sat, 08 Dec 2012 12:40:21 -0000\r
74 \r
75 --bcaec55408906f390304d056a254\r
76 Content-Type: text/plain; charset=ISO-8859-1\r
77 \r
78 On 7 December 2012 16:32, Jason A. Donenfeld <Jason@zx2c4.com> wrote:\r
79 \r
80 >\r
81 >\r
82 > On Fri, Dec 7, 2012 at 2:57 PM, Rainer M Krug <r.m.krug@gmail.com> wrote:\r
83 >>\r
84 >>  >\r
85 >> >\r
86 >> > 2) I am downloading with the patched notmuch (to add x-keywords\r
87 >> containing the labels) only\r
88 >> > the "All Mail" folder - does your script use this information (if\r
89 >> present) to tag the emails?\r
90 >> >\r
91 >> >\r
92 >> > What is the patched notmuch? What does that do?\r
93 >>\r
94 >> Sorry - should have been "patched offlineimap" (\r
95 >> https://github.com/aroig/offlineimap\r
96 >>\r
97 >> http://thread.gmane.org/gmane.mail.imap.offlineimap.general/5943/focus=5970and\r
98 >> http://article.gmane.org/gmane.mail.imap.offlineimap.general/5970 )\r
99 >>\r
100 >> It is synching the gmail labels into the x-keywords header as a comma\r
101 >> separated list. These could\r
102 >> then be used by notmuch to be added to the labels. It also does sync\r
103 >> changes from the X-Keywords\r
104 >> to gmail (see\r
105 >> http://thread.gmane.org/gmane.mail.imap.offlineimap.general/5943/focus=5970for details)\r
106 >\r
107 >\r
108 > I see.\r
109 >\r
110 > I use the All Mail folder and get the tags using the X-GM-LABELS imap\r
111 > extension. I don't muck with the mail headers in the process, fortunately.\r
112 >\r
113 \r
114 I actually prefer this approach, but I think it would be more useful to\r
115 leave the syncing of the emails to a different program, and then just\r
116 managing the labels / tags with your tool (which is notmuch territory). So\r
117 the workflow would be:\r
118 \r
119 Initial or download (only remote changes):\r
120 \r
121 1) Download email ("All Mail" folder) with whatever you are using\r
122 (offlinemail, ...)\r
123 2) call your script to index the downloaded emails (All Mail" folder) with\r
124 notmuch and get the labels and set / remove them in notmuch accordingly.\r
125 \r
126 Upload (only local changes):\r
127 \r
128 1) upload emails using whatever (offlineimap, ...)\r
129 2) upload the changed tags and create the needed new labels (and possibly\r
130 delete empty ons?)\r
131 \r
132 The tricky part will be the synching when changes on both sides were\r
133 observed.\r
134 The mail sync is implemented in e.g. offlineimap and works reilably. But I\r
135 don't know how one could handle tag / label changes on both sides.\r
136 \r
137 So, implementing the mail sync in this script would, as I see it, kind of\r
138 reinventing the wheel. One can leave it in, but I would like to have an\r
139 option to leave the synching of the emails to a separate program.\r
140 \r
141 Cheers,\r
142 \r
143 Rainer\r
144 \r
145 \r
146 \r
147 -- \r
148 NEW GERMAN FAX NUMBER!!!\r
149 \r
150 Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology,\r
151 UCT), Dipl. Phys. (Germany)\r
152 \r
153 Centre of Excellence for Invasion Biology\r
154 Natural Sciences Building\r
155 Office Suite 2039\r
156 Stellenbosch University\r
157 Main Campus, Merriman Avenue\r
158 Stellenbosch\r
159 South Africa\r
160 \r
161 Cell:           +27 - (0)83 9479 042\r
162 Fax:            +27 - (0)86 516 2782\r
163 Fax:            +49 - (0)321 2125 2244\r
164 email:          Rainer@krugs.de\r
165 \r
166 Skype:          RMkrug\r
167 Google:         R.M.Krug@gmail.com\r
168 \r
169 --bcaec55408906f390304d056a254\r
170 Content-Type: text/html; charset=ISO-8859-1\r
171 Content-Transfer-Encoding: quoted-printable\r
172 \r
173 <br><div class=3D"gmail_extra"><br><br><div class=3D"gmail_quote">On 7 Dece=\r
174 mber 2012 16:32, Jason A. Donenfeld <span dir=3D"ltr">&lt;<a href=3D"mailto=\r
175 :Jason@zx2c4.com" target=3D"_blank">Jason@zx2c4.com</a>&gt;</span> wrote:<b=\r
176 r><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:=\r
177 1px #ccc solid;padding-left:1ex">\r
178 <br><br><div class=3D"gmail_quote"><div class=3D"im">On Fri, Dec 7, 2012 at=\r
179  2:57 PM, Rainer M Krug <span dir=3D"ltr">&lt;<a href=3D"mailto:r.m.krug@gm=\r
180 ail.com" target=3D"_blank">r.m.krug@gmail.com</a>&gt;</span> wrote:<blockqu=\r
181 ote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc s=\r
182 olid;padding-left:1ex">\r
183 \r
184 <div>\r
185 &gt;<br>\r
186 &gt;<br>\r
187 &gt; 2) I am downloading with the patched notmuch (to add x-keywords contai=\r
188 ning the labels) only<br>\r
189 &gt; the &quot;All Mail&quot; folder - does your script use this informatio=\r
190 n (if present) to tag the emails?<br>\r
191 &gt;<br>\r
192 &gt;<br>\r
193 &gt; What is the patched notmuch? What does that do?<br>\r
194 <br>\r
195 </div>Sorry - should have been &quot;patched offlineimap&quot; ( <a href=3D=\r
196 "https://github.com/aroig/offlineimap" target=3D"_blank">https://github.com=\r
197 /aroig/offlineimap</a><br>\r
198 <a href=3D"http://thread.gmane.org/gmane.mail.imap.offlineimap.general/5943=\r
199 /focus=3D5970" target=3D"_blank">http://thread.gmane.org/gmane.mail.imap.of=\r
200 flineimap.general/5943/focus=3D5970</a> and<br>\r
201 <a href=3D"http://article.gmane.org/gmane.mail.imap.offlineimap.general/597=\r
202 0" target=3D"_blank">http://article.gmane.org/gmane.mail.imap.offlineimap.g=\r
203 eneral/5970</a> )<br>\r
204 <br>\r
205 It is synching the gmail labels into the x-keywords header as a comma separ=\r
206 ated list. These could<br>\r
207 then be used by notmuch to be added to the labels. It also does sync change=\r
208 s from the X-Keywords<br>\r
209 to gmail (see <a href=3D"http://thread.gmane.org/gmane.mail.imap.offlineima=\r
210 p.general/5943/focus=3D5970" target=3D"_blank">http://thread.gmane.org/gman=\r
211 e.mail.imap.offlineimap.general/5943/focus=3D5970</a> for details)</blockqu=\r
212 ote>\r
213 \r
214 <div><br></div></div><div>I see.</div><div><br></div><div>I use the All Mai=\r
215 l folder and get the tags using the X-GM-LABELS imap extension. I don&#39;t=\r
216  muck with the mail headers in the process, fortunately.</div></div></block=\r
217 quote>\r
218 <div><br>I actually prefer this approach, but I think it would be more usef=\r
219 ul to leave the syncing of the emails to a different program, and then just=\r
220  managing the labels / tags with your tool (which is notmuch territory). So=\r
221  the workflow would be:<br>\r
222 <br>Initial or download (only remote changes):<br><br>1) Download email (&q=\r
223 uot;All Mail&quot; folder) with whatever you are using (offlinemail, ...)<b=\r
224 r>2) call your script to index the downloaded emails (All Mail&quot; folder=\r
225 ) with notmuch and get the labels and set / remove them in notmuch accordin=\r
226 gly. <br>\r
227 <br>Upload (only local changes):<br><br>1) upload emails using whatever (of=\r
228 flineimap, ...)<br>2) upload the changed tags and create the needed new lab=\r
229 els (and possibly delete empty ons?)<br><br>The tricky part will be the syn=\r
230 ching when changes on both sides were observed.<br>\r
231 The mail sync is implemented in e.g. offlineimap and works reilably. But I =\r
232 don&#39;t know how one could handle tag / label changes on both sides.<br><=\r
233 br>So, implementing the mail sync in this script would, as I see it, kind o=\r
234 f reinventing the wheel. One can leave it in, but I would like to have an o=\r
235 ption to leave the synching of the emails to a separate program.<br>\r
236 <br>Cheers,<br><br>Rainer <br></div></div><br><br clear=3D"all"><br>-- <br>=\r
237 NEW GERMAN FAX NUMBER!!!<br><br>Rainer M. Krug, PhD (Conservation Ecology, =\r
238 SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany)<br><br>Centre =\r
239 of Excellence for Invasion Biology<br>\r
240 Natural Sciences Building<br>Office Suite 2039<br>Stellenbosch University<b=\r
241 r>Main Campus, Merriman Avenue<br>Stellenbosch<br>South Africa<br><br>Cell:=\r
242 =A0 =A0 =A0 =A0 =A0=A0 +27 - (0)83 9479 042<br>Fax:=A0 =A0 =A0 =A0 =A0 =A0 =\r
243 +27 - (0)86 516 2782<br>\r
244 Fax:=A0 =A0 =A0 =A0 =A0 =A0 +49 - (0)321 2125 2244<br>email:=A0 =A0 =A0 =A0=\r
245  =A0 <a href=3D"mailto:Rainer@krugs.de" target=3D"_blank">Rainer@krugs.de</=\r
246 a><br><br>Skype:=A0 =A0 =A0 =A0 =A0 RMkrug<br>Google:=A0 =A0 =A0 =A0=A0 <a =\r
247 href=3D"mailto:R.M.Krug@gmail.com" target=3D"_blank">R.M.Krug@gmail.com</a>=\r
248 <br>\r
249 <br>\r
250 </div>\r
251 \r
252 --bcaec55408906f390304d056a254--\r