Missing headers when forwarding html message as RFC822
[notmuch-archives.git] / 7e / d4be86e03c0be028c38c424795489cb4806991
1 Return-Path: <schnouki@schnouki.net>\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 EDDBE429E28\r
6         for <notmuch@notmuchmail.org>; Tue, 13 Dec 2011 09:12:09 -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.1\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-0.1 tagged_above=-999 required=5\r
12         tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1]\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 puNn2LE3EOTM for <notmuch@notmuchmail.org>;\r
17         Tue, 13 Dec 2011 09:12:09 -0800 (PST)\r
18 Received: from ks3536.kimsufi.com (schnouki.net [87.98.217.222])\r
19         by olra.theworths.org (Postfix) with ESMTP id E8EC8429E25\r
20         for <notmuch@notmuchmail.org>; Tue, 13 Dec 2011 09:12:08 -0800 (PST)\r
21 Received: from thor.loria.fr (thor.loria.fr [152.81.12.250])\r
22         by ks3536.kimsufi.com (Postfix) with ESMTPSA id C491D6A0026;\r
23         Tue, 13 Dec 2011 18:12:07 +0100 (CET)\r
24 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=schnouki.net;\r
25         s=key-schnouki; t=1323796327;\r
26         bh=8CV2PirzdQgi3G82froq5+HvXxRthKJ/3+tfZJVPYYA=;\r
27         h=From:To:Subject:Date:Message-Id;\r
28         b=m0JZCcwGOrrlfZqgtNQridMZzmBQWR3d0flp/pQTyFgU69mSREKPk0u20hWPPnGWz\r
29         j1PRyTrbzl8bMOr5mGPiXTSzy45PT5WrJbCseMOR2LLxiV2+R+9CifmInlJBro7qJF\r
30         hTeayDeUV7yc+jxLlBJFOe+Q9yax5GeI2D2vVAsA=\r
31 From: Thomas Jost <schnouki@schnouki.net>\r
32 To: notmuch@notmuchmail.org\r
33 Subject: [PATCH 0/5] Store message modification times in the DB\r
34 Date: Tue, 13 Dec 2011 18:11:40 +0100\r
35 Message-Id: <1323796305-28789-1-git-send-email-schnouki@schnouki.net>\r
36 X-Mailer: git-send-email 1.7.8\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, 13 Dec 2011 17:12:10 -0000\r
50 \r
51 Hello world,\r
52 \r
53 This is a patch series I've been working on for some time in order to be\r
54 able to sync my tags on several computers. I'm posting it now, but\r
55 please consider it as a RFC rather than something that is ready to be\r
56 pushed.\r
57 \r
58 The basic idea is to the last time each message was modified, i.e. "the\r
59 message was added to the DB", "a tag was added" or "a tag was removed".\r
60 \r
61 This mtime is accessible through a library function and in the JSON\r
62 output of "notmuch show". It is also searchable with the "mtime:" prefix\r
63 and with timestamp ranges, like for searching messages by date:\r
64 \r
65     notmuch search mtime:$(date +%s 2011-12-01)..$(date +%s)\r
66 \r
67 This can then be used in scripts or helper programs to do incremental\r
68 dumps or tags synchronization. (I already have a script to do\r
69 incremental backups, but it needs some cleaning, and I'm still working\r
70 on something for sync'ing tags, but it's starting to work really well;\r
71 I'll post them later).\r
72 \r
73 This can be seen as an alternative to David Bremner's jlog branch, but\r
74 with several differences:\r
75 \r
76 + no external dependency\r
77 + everything is stored in the notmuch DB: atomicity for free!\r
78 - when a message is removed we lose everything about it, which makes the\r
79   sync process more complicated\r
80 - for a human, it's harder to manipulate timestamps than log messages\r
81 - this can store much less data than a proper log system\r
82 \r
83 On IRC amdragon suggested using a simple sequence number instead of a\r
84 timestamp. This would indeed eliminate the need for proper time\r
85 synchronization between computers one would want to keep in sync, and it\r
86 would reduce the risk of time-going-backward problems, but IMHO it would\r
87 cause more problems: no global clock --> no simple way to tell if DB #A\r
88 is more recent than DB #B.\r
89 \r
90 So, here are the patches:\r
91 - first a little fix to the comments describing the DB schema (not\r
92   specific to this patch series at all, I just noticed it when rebasing\r
93   this series)\r
94 - the second commit adds the MTIME value to the database schema, and\r
95   creates the functions used to update and access this value.\r
96 - the third commit makes the MTIME value searchable with a range syntax.\r
97 - the fourth commit adds the MTIME to the JSON output of "notmuch show".\r
98 - the fifth and last commit adds Message.get_mtime() to the Python\r
99   bindings.\r
100 \r
101 Please tell me what you think of this.\r
102 \r
103 Best regards,\r
104 Thomas\r
105 \r
106 Thomas Jost (5):\r
107   Fix comments about what is stored in the database\r
108   lib: Add a MTIME value to every mail document\r
109   lib: Make MTIME values searchable\r
110   show: include mtime in JSON output\r
111   python: add get_mtime() to the Message class\r
112 \r
113  bindings/python/notmuch/message.py |   20 ++++++++++++++++++++\r
114  lib/database-private.h             |    1 +\r
115  lib/database.cc                    |   14 +++++++++++++-\r
116  lib/message.cc                     |   32 ++++++++++++++++++++++++++++++++\r
117  lib/notmuch-private.h              |    6 +++++-\r
118  lib/notmuch.h                      |    4 ++++\r
119  notmuch-show.c                     |    7 ++++---\r
120  notmuch.1                          |   14 ++++++++++++--\r
121  notmuch.c                          |   13 ++++++++++---\r
122  9 files changed, 101 insertions(+), 10 deletions(-)\r
123 \r
124 -- \r
125 1.7.8\r
126 \r