[PATCH v2 5/8] notmuch-new: pull out useful bits of add_files_recursive

2012-07-01 Thread Mark Walters
On Sun, 01 Jul 2012, Ethan Glasser-Camp wrote: > This patch pulls some bits out of add_files_recursive which will be > useful for other backends: two reporting functions > _report_before_adding_file and _report_added_file, as well as > _add_message, which actually does the message adding. > > No

[PATCH v2 1/8] All access to mail files goes through the mailstore module

2012-07-01 Thread Mark Walters
On Sun, 01 Jul 2012, Ethan Glasser-Camp wrote: > This commit introduces the mailstore module which provides two > functions, notmuch_mailstore_open and notmuch_mailstore_close. These > functions are currently just stub calls to fopen and fclose, but later > can be made more complex in order to

[PATCH] cli: notmuch-show with framing newlines between threads in JSON.

2012-07-01 Thread Austin Clements
Quoth Tomi Ollila on Jul 02 at 1:13 am: > On Sat, Jun 30 2012, Mark Walters wrote: > > > Add newlines between complete threads to make asynchronous parsing > > of the JSON easier. > > --- > > > > notmuch-pick uses the JSON output of notmuch show but, in many cases, > > for many threads. This

[RFC PATCH 00/14] modular mail stores based on URIs

2012-07-01 Thread Mark Walters
On Sun, 01 Jul 2012, Ethan wrote: > Thanks for going through it, I know there's a lot to go through.. > > On Thu, Jun 28, 2012 at 4:45 PM, Mark Walters gmail.com>wrote: > >> I was thinking of just having one mail root and inside that there could >> be maildirs and mboxes. Everything would still

[PATCH v2 8/8] new: Add scan support for mbox:// URIs

2012-07-01 Thread Ethan Glasser-Camp
This fixes the broken tests introduced by the last commit. Signed-off-by: Ethan Glasser-Camp --- More text was added to clarify how mbox scanning works. notmuch-config.c |4 + notmuch-new.c| 304 +- 2 files changed, 303

[PATCH v2 7/8] Tests for mbox support

2012-07-01 Thread Ethan Glasser-Camp
These are simple tests of one single mbox. Signed-off-by: Ethan Glasser-Camp --- The test uses bash arrays, which have a slightly odd syntax for appending. test/mbox | 63 + test/notmuch-test |1 + 2 files changed, 64

[PATCH v2 6/8] mailstore: support for mbox:// URIs

2012-07-01 Thread Ethan Glasser-Camp
No code uses this yet. Signed-off-by: Ethan Glasser-Camp --- lib/mailstore.c | 117 ++- 1 file changed, 116 insertions(+), 1 deletion(-) diff --git a/lib/mailstore.c b/lib/mailstore.c index 48acd47..a29d734 100644 --- a/lib/mailstore.c +++

[PATCH v2 5/8] notmuch-new: pull out useful bits of add_files_recursive

2012-07-01 Thread Ethan Glasser-Camp
This patch pulls some bits out of add_files_recursive which will be useful for other backends: two reporting functions _report_before_adding_file and _report_added_file, as well as _add_message, which actually does the message adding. No functional changes. Signed-off-by: Ethan Glasser-Camp ---

[PATCH v2 4/8] new: add "scan" option

2012-07-01 Thread Ethan Glasser-Camp
The new.scan option is a list of URLs that can be "scanned". The fact that the database maildir is scanned "automagically" is a little weird, but it doesn't do any harm unless you decide to put mail there that you really don't want indexed. Signed-off-by: Ethan Glasser-Camp --- I added text

[PATCH v2 3/8] Not all filenames need to be converted to absolute paths

2012-07-01 Thread Ethan Glasser-Camp
_notmuch_message_ensure_filename_list converts "relative" paths, such as those stored in Xapian until now, to "absolute" paths. However, URLs are already absolute, and prepending the database path will just confuse matters. Signed-off-by: Ethan Glasser-Camp --- lib/message.cc | 20

[PATCH v2 2/8] Introduce uriparser

2012-07-01 Thread Ethan Glasser-Camp
Seeing as there is no glib-standard way to parse URIs, an external library is needed. This commit introduces another program in compat/ and a stanza in ./configure to test if uriparser is there. Signed-off-by: Ethan Glasser-Camp --- Makefile.local |2 +- compat/have_uriparser.c |

[PATCH v2 1/8] All access to mail files goes through the mailstore module

2012-07-01 Thread Ethan Glasser-Camp
This commit introduces the mailstore module which provides two functions, notmuch_mailstore_open and notmuch_mailstore_close. These functions are currently just stub calls to fopen and fclose, but later can be made more complex in order to support mail storage systems where one message might not

[PATCH v2 0/8] URI-based modular mail stores

2012-07-01 Thread Ethan Glasser-Camp
Hi guys, Based on the feedback from the last patch series (thanks a lot to Mark Walters and Jani Nikula for taking the time to look at it!) I revised this patch series to not change the handling of maildir filenames at all. This meant not having to give up relocatability, and also simplified the

[RFC PATCH 00/14] modular mail stores based on URIs

2012-07-01 Thread Ethan
backwardly compatible. > Based on your and Jani's reasoning, I did this. Revised patch series follows. Ethan -- next part -- An HTML attachment was scrubbed... URL: <http://notmuchmail.org/pipermail/notmuch/attachments/20120701/a3c4b5d3/attachment.html>

Re: [RFC PATCH 00/14] modular mail stores based on URIs

2012-07-01 Thread Ethan
Thanks for going through it, I know there's a lot to go through.. On Thu, Jun 28, 2012 at 4:45 PM, Mark Walters markwalters1...@gmail.comwrote: I was thinking of just having one mail root and inside that there could be maildirs and mboxes. Everything would still be relative to the root. I'm

[PATCH v2 1/8] All access to mail files goes through the mailstore module

2012-07-01 Thread Ethan Glasser-Camp
This commit introduces the mailstore module which provides two functions, notmuch_mailstore_open and notmuch_mailstore_close. These functions are currently just stub calls to fopen and fclose, but later can be made more complex in order to support mail storage systems where one message might not

[PATCH v2 2/8] Introduce uriparser

2012-07-01 Thread Ethan Glasser-Camp
Seeing as there is no glib-standard way to parse URIs, an external library is needed. This commit introduces another program in compat/ and a stanza in ./configure to test if uriparser is there. Signed-off-by: Ethan Glasser-Camp et...@betacantrips.com --- Makefile.local |2 +-

[PATCH v2 3/8] Not all filenames need to be converted to absolute paths

2012-07-01 Thread Ethan Glasser-Camp
_notmuch_message_ensure_filename_list converts relative paths, such as those stored in Xapian until now, to absolute paths. However, URLs are already absolute, and prepending the database path will just confuse matters. Signed-off-by: Ethan Glasser-Camp et...@betacantrips.com --- lib/message.cc

[PATCH v2 4/8] new: add scan option

2012-07-01 Thread Ethan Glasser-Camp
The new.scan option is a list of URLs that can be scanned. The fact that the database maildir is scanned automagically is a little weird, but it doesn't do any harm unless you decide to put mail there that you really don't want indexed. Signed-off-by: Ethan Glasser-Camp et...@betacantrips.com

[PATCH v2 5/8] notmuch-new: pull out useful bits of add_files_recursive

2012-07-01 Thread Ethan Glasser-Camp
This patch pulls some bits out of add_files_recursive which will be useful for other backends: two reporting functions _report_before_adding_file and _report_added_file, as well as _add_message, which actually does the message adding. No functional changes. Signed-off-by: Ethan Glasser-Camp

[PATCH v2 6/8] mailstore: support for mbox:// URIs

2012-07-01 Thread Ethan Glasser-Camp
No code uses this yet. Signed-off-by: Ethan Glasser-Camp et...@betacantrips.com --- lib/mailstore.c | 117 ++- 1 file changed, 116 insertions(+), 1 deletion(-) diff --git a/lib/mailstore.c b/lib/mailstore.c index 48acd47..a29d734 100644 ---

[PATCH v2 7/8] Tests for mbox support

2012-07-01 Thread Ethan Glasser-Camp
These are simple tests of one single mbox. Signed-off-by: Ethan Glasser-Camp et...@betacantrips.com --- The test uses bash arrays, which have a slightly odd syntax for appending. test/mbox | 63 + test/notmuch-test |1 + 2 files

[PATCH v2 8/8] new: Add scan support for mbox:// URIs

2012-07-01 Thread Ethan Glasser-Camp
This fixes the broken tests introduced by the last commit. Signed-off-by: Ethan Glasser-Camp et...@betacantrips.com --- More text was added to clarify how mbox scanning works. notmuch-config.c |4 + notmuch-new.c| 304 +- 2 files

Re: [PATCH v2 1/8] All access to mail files goes through the mailstore module

2012-07-01 Thread Mark Walters
On Sun, 01 Jul 2012, Ethan Glasser-Camp ethan.glasser.c...@gmail.com wrote: This commit introduces the mailstore module which provides two functions, notmuch_mailstore_open and notmuch_mailstore_close. These functions are currently just stub calls to fopen and fclose, but later can be made

Re: [PATCH v2 5/8] notmuch-new: pull out useful bits of add_files_recursive

2012-07-01 Thread Mark Walters
On Sun, 01 Jul 2012, Ethan Glasser-Camp ethan.glasser.c...@gmail.com wrote: This patch pulls some bits out of add_files_recursive which will be useful for other backends: two reporting functions _report_before_adding_file and _report_added_file, as well as _add_message, which actually does the

Re: [PATCH] cli: notmuch-show with framing newlines between threads in JSON.

2012-07-01 Thread Tomi Ollila
On Sat, Jun 30 2012, Mark Walters markwalters1...@gmail.com wrote: Add newlines between complete threads to make asynchronous parsing of the JSON easier. --- notmuch-pick uses the JSON output of notmuch show but, in many cases, for many threads. This can take quite a long time when

Re: [PATCH] cli: notmuch-show with framing newlines between threads in JSON.

2012-07-01 Thread Mark Walters
On Sun, 01 Jul 2012, Tomi Ollila tomi.oll...@iki.fi wrote: On Sat, Jun 30 2012, Mark Walters markwalters1...@gmail.com wrote: Add newlines between complete threads to make asynchronous parsing of the JSON easier. --- notmuch-pick uses the JSON output of notmuch show but, in many cases, for

Re: [PATCH] cli: notmuch-show with framing newlines between threads in JSON.

2012-07-01 Thread Austin Clements
Quoth Tomi Ollila on Jul 02 at 1:13 am: On Sat, Jun 30 2012, Mark Walters markwalters1...@gmail.com wrote: Add newlines between complete threads to make asynchronous parsing of the JSON easier. --- notmuch-pick uses the JSON output of notmuch show but, in many cases, for many

Re: [PATCH] cli: notmuch-show with framing newlines between threads in JSON.

2012-07-01 Thread Austin Clements
Quoth myself on Jul 01 at 8:12 pm: Quoth Tomi Ollila on Jul 02 at 1:13 am: On Sat, Jun 30 2012, Mark Walters markwalters1...@gmail.com wrote: Add newlines between complete threads to make asynchronous parsing of the JSON easier. --- notmuch-pick uses the JSON output of