Re: Possible addtions to notmuch new ?
[notmuch-archives.git] / a6 / 707d89a8b3092de64adb1620b68f2a5ad6a151
1 Return-Path: <tomi.ollila@nixu.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 92341429E25\r
6         for <notmuch@notmuchmail.org>; Fri, 16 Dec 2011 06:18:38 -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 9ifuY+xzT4rC for <notmuch@notmuchmail.org>;\r
16         Fri, 16 Dec 2011 06:18:37 -0800 (PST)\r
17 Received: from mail-gw3.nixu.fi (mail-gw3.nixu.fi [193.209.237.7])\r
18         (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))\r
19         (No client certificate requested)\r
20         by olra.theworths.org (Postfix) with ESMTPS id 6106D431FD0\r
21         for <notmuch@notmuchmail.org>; Fri, 16 Dec 2011 06:18:37 -0800 (PST)\r
22 Received: from pps.filterd (mail-gw3 [127.0.0.1])\r
23         by mail-gw3.nixu.fi (8.14.4/8.14.4) with SMTP id pBGEIOQI027370;\r
24         Fri, 16 Dec 2011 16:18:24 +0200\r
25 Received: from taco2.nixu.fi (taco2.nixu.fi [194.197.118.31])\r
26         by mail-gw3.nixu.fi with ESMTP id 114cs0ts2k-1\r
27         (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT);\r
28         Fri, 16 Dec 2011 16:18:24 +0200\r
29 Received: from taco2.nixu.fi (taco2.nixu.fi [194.197.118.31])\r
30         by taco2.nixu.fi (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id\r
31         pBGEIM3U031984; Fri, 16 Dec 2011 16:18:23 +0200\r
32 From: Tomi Ollila <tomi.ollila@iki.fi>\r
33 To: Philipp =?utf-8?Q?=C3=9Cberbacher?= <murks@lavabit.com>, Tomi Ollila\r
34         <tomi.ollila@iki.fi>, notmuch@notmuchmail.org\r
35 Subject: Re: ANNOUNCE: nottoomuch-addresses.pl version 1.4\r
36 In-Reply-To: <20111216130128.E918211BC52@karen.lavabit.com>\r
37 References: <m2d3c8e22v.fsf@guru.guru-group.fi>\r
38         <yf6wraf5sq2.fsf@taco2.nixu.fi> <yf68vmr5j9n.fsf@taco2.nixu.fi>\r
39         <m2pqg32pic.fsf@ursys.com.au> <yf662hv5h8o.fsf@taco2.nixu.fi>\r
40         <87wrabmb43.fsf@servo.finestructure.net>\r
41         <m2k46a3d6a.fsf@ursys.com.au> <yf639cx5peg.fsf@taco2.nixu.fi>\r
42         <yf6k461n5ca.fsf@taco2.nixu.fi> <yf662hiap8r.fsf@taco2.nixu.fi>\r
43         <20111216130128.E918211BC52@karen.lavabit.com>\r
44 User-Agent: Notmuch/0.10.2+93~g631d290 (http://notmuchmail.org) Emacs/23.3.1\r
45         (i686-pc-linux-gnu)\r
46 X-Face: HhBM'cA~<r"^Xv\KRN0P{vn'Y"Kd;zg_y3S[4)KSN~s?O\"QPoL\r
47         $[Xv_BD:i/F$WiEWax}R(MPS`^UaptOGD`*/=@\1lKoVa9tnrg0TW?"r7aRtgk[F\r
48         !)g;OY^,BjTbr)Np:%c_o'jj,Z\r
49 Date: Fri, 16 Dec 2011 16:18:22 +0200\r
50 Message-ID: <yf6k45wfvm9.fsf@taco2.nixu.fi>\r
51 MIME-Version: 1.0\r
52 Content-Type: text/plain; charset=utf-8\r
53 Content-Transfer-Encoding: quoted-printable\r
54 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.5.7110,\r
55  1.0.211,       0.0.0000        definitions=2011-12-16_05:2011-12-16, 2011-12-16,\r
56         1970-01-01 signatures=0\r
57 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0\r
58         ipscore=0 suspectscore=0\r
59         phishscore=0 bulkscore=0 adultscore=0 classifier=spam adjust=0\r
60         reason=mlx\r
61         scancount=1 engine=6.0.2-1012030000 definitions=main-1112160105\r
62 X-BeenThere: notmuch@notmuchmail.org\r
63 X-Mailman-Version: 2.1.13\r
64 Precedence: list\r
65 List-Id: "Use and development of the notmuch mail system."\r
66         <notmuch.notmuchmail.org>\r
67 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
68         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
69 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
70 List-Post: <mailto:notmuch@notmuchmail.org>\r
71 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
72 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
73         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
74 X-List-Received-Date: Fri, 16 Dec 2011 14:18:38 -0000\r
75 \r
76 On Fri, 16 Dec 2011 14:01:26 +0100, Philipp =C3=9Cberbacher <murks@lavabit.=\r
77 com> wrote:\r
78 > Quoting Tomi Ollila (2011-12-14 21:10:28)\r
79 >=20\r
80 > Hi Tomi,\r
81 > can this be used to automatically populate abook?\r
82 > I wonder because alot uses abook for addresses, and this could be handy.\r
83 \r
84 Converter from 'flat list of email-addresses' in\r
85 $HOME/.config/nottoomuch/addresses to abook format is probably pretty\r
86 trivial (unless it is binary which lessens triviality...)... But there\r
87 could be (updating) issues.\r
88 \r
89 Alternative would be to run something like\r
90 \r
91   notmuch search --sort=3Dnewest-first --output=3Dfiles '*' |=20\r
92   while read file; do abook --add-email "$file"; done\r
93 \r
94 initially. then register current date using date=3D`$date +%s`\r
95 \r
96 and, in following rounds run\r
97 \r
98   notmuch search --sort=3Dnewest-first --output=3Dfiles $(($date - 604800))=\r
99 .. |=20\r
100   while read file; do abook --add-email "$file"; done\r
101 \r
102 (604800 =3D=3D 86400 * 7 -- 7 days -- just analogous what nottoomuch-addres=\r
103 ses.sh\r
104 does)\r
105 \r
106 Note that this is just untested example (read abook.1 a bit)\r
107 \r
108 \r
109 An alternative would be to make 'abook' run nottoomuch-addresses.sh for\r
110 address completion (then get it's output order for matches (email addresses\r
111 from recent messages first)) -- or even just run\r
112 \r
113   grep -aiF "$string" "${XDG_CONFIG_HOME:-$HOME/.config}/nottoomuch/address=\r
114 es"\r
115 \r
116 (this is what nottoomuch-addresses.sh does when finding matches for given\r
117 search string. One can imagine how fast this approach is...)\r
118 \r
119 > Regards,\r
120 > Philipp\r
121 \r
122 Tomi\r