Re: [PATCH v2] VIM: Use notmuch CLI for config

2014-10-02 Thread David Bremner
Ian Main writes: > This patch switches from reading .notmuch-config directly to using > the CLI the same way that emacs does it. It actually uses less code > and is probably less error prone. > > Ian The general approach seems sane; it seems quite brittle to read the config file directly. I

[PATCH] VIM: Better reply handling with multiple emails

2014-10-02 Thread Ian Main
This patch fixes reply handling when using multiple emails. This adds a config check for other_email and uses that information when formulating reply headers. It will strip out your own email addresses from the reply and set the From: to be an email of yours found in the original message. Note t

[PATCH] VIM: Better reply handling with multiple emails

2014-10-02 Thread Ian Main
This patch fixes reply handling when using multiple emails. This adds a config check for other_email and uses that information when formulating reply headers. It will strip out your own email addresses from the reply and set the From: to be an email of yours found in the original message. Note t

[PATCH v2] VIM: Use notmuch CLI for config

2014-10-02 Thread Ian Main
This patch switches from reading .notmuch-config directly to using the CLI the same way that emacs does it. It actually uses less code and is probably less error prone. Ian --- This update changes result to be '' instead of nil by default so missing config items won't cause an error. vim/n

[PATCH v2] VIM: Use notmuch CLI for config

2014-10-02 Thread Ian Main
This patch switches from reading .notmuch-config directly to using the CLI the same way that emacs does it. It actually uses less code and is probably less error prone. Ian --- This update changes result to be '' instead of nil by default so missing config items won't cause an error. vim/n

[PATCH v4] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread Austin Clements
On Thu, 02 Oct 2014, "W. Trevor King" wrote: > On Thu, Oct 02, 2014 at 03:19:08PM -0400, Austin Clements wrote: >> This patch simplifies notmuch_database_close to explicitly abort any >> outstanding transaction and then just call Database::close. This >> works for both read-only and read/write da

[PATCH v4] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread Austin Clements
From: Austin Clements In Xapian, closing a database implicitly aborts any outstanding transaction and commits changes. For historical reasons, notmuch_database_close had grown to almost, but not quite duplicate this behavior. Before closing the database, it would explicitly (and unnecessarily)

[PATCH v3] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread Austin Clements
On Wed, 24 Sep 2014, "W. Trevor King" wrote: > On Wed, Sep 24, 2014 at 05:32:50PM -0400, Austin Clements wrote: >> + * If the caller is currently in an atomic section (there was a >> + * notmuch_database_begin_atomic without a matching >> + * notmuch_database_end_atomic), this will abort the atomi

[PATCH] VIM: Use notmuch CLI for config

2014-10-02 Thread Ian Main
This patch switches from reading .notmuch-config directly to using the CLI the same way that emacs does it. It actually uses less code and is probably less error prone. Ian --- vim/notmuch.vim | 31 --- 1 file changed, 12 insertions(+), 19 deletions(-) diff --git

[PATCH] VIM: Use notmuch CLI for config

2014-10-02 Thread Ian Main
This patch switches from reading .notmuch-config directly to using the CLI the same way that emacs does it. It actually uses less code and is probably less error prone. Ian --- vim/notmuch.vim | 31 --- 1 file changed, 12 insertions(+), 19 deletions(-) diff --git

Re: [PATCH v4] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread W. Trevor King
On Thu, Oct 02, 2014 at 04:39:41PM -0400, Austin Clements wrote: > On Thu, 02 Oct 2014, W. Trevor King wrote: > > On Thu, Oct 02, 2014 at 03:19:08PM -0400, Austin Clements wrote: > >> This patch simplifies notmuch_database_close to explicitly abort > >> any outstanding transaction and then just cal

[PATCH v4] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread W. Trevor King
This email may be signed or encrypted with GnuPG (http://www.gnupg.org). For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy -- next part -- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: OpenPGP digital signature URL: <http://notmuchmail.org/pipermail/notmuch/attachments/20141002/e2fe9c19/attachment.pgp>

Re: [PATCH v4] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread Austin Clements
On Thu, 02 Oct 2014, "W. Trevor King" wrote: > On Thu, Oct 02, 2014 at 03:19:08PM -0400, Austin Clements wrote: >> This patch simplifies notmuch_database_close to explicitly abort any >> outstanding transaction and then just call Database::close. This >> works for both read-only and read/write da

[PATCH] VIM: Add URI handling

2014-10-02 Thread Ian Main
This patch adds URI handling to the vim client. You can now press 'u' by default and the client will parse the current line and find any URIs available. If there are more than one it opens the one under the cursor or else it opens the only one available. It also supports mailto: URI's and will c

notmuch-vim doesn't respect notmuch config defaults

2014-10-02 Thread David Bremner
Sergei Shilovsky writes: > I would suggest to use `notmuch config list` to get configuration > values in vim if possible I guess this is a general question we haven't really resolved, namely sharing configuration information between various notmuch frontends. .notmuch-config is really the config

[PATCH] VIM: Add URI handling

2014-10-02 Thread Ian Main
This patch adds URI handling to the vim client. You can now press 'u' by default and the client will parse the current line and find any URIs available. If there are more than one it opens the one under the cursor or else it opens the only one available. It also supports mailto: URI's and will c

notmuch-vim doesn't respect notmuch config defaults

2014-10-02 Thread Sergei Shilovsky
I would suggest to use `notmuch config list` to get configuration values in vim if possible Reproduction example follows: /home/sh> cat .notmuch-config [new] tags=new;inbox;unread ignore= [search] exclude_tags=deleted;spam [maildir] synchronize_flags=false /home/sh> notmuch config lis

Re: [PATCH v4] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread W. Trevor King
On Thu, Oct 02, 2014 at 03:19:08PM -0400, Austin Clements wrote: > This patch simplifies notmuch_database_close to explicitly abort any > outstanding transaction and then just call Database::close. This > works for both read-only and read/write databases, takes care of > committing changes, unifie

[PATCH v4] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread W. Trevor King
- next part -- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: OpenPGP digital signature URL: <http://notmuchmail.org/pipermail/notmuch/attachments/20141002/6a1b6789/attachment.pgp>

Re: notmuch-vim doesn't respect notmuch config defaults

2014-10-02 Thread Ian Main
David Bremner wrote: > Sergei Shilovsky writes: > > > I would suggest to use `notmuch config list` to get configuration > > values in vim if possible > > I guess this is a general question we haven't really resolved, namely > sharing configuration information between various notmuch frontends. >

notmuch-vim doesn't respect notmuch config defaults

2014-10-02 Thread Ian Main
David Bremner wrote: > Sergei Shilovsky writes: > > > I would suggest to use `notmuch config list` to get configuration > > values in vim if possible > > I guess this is a general question we haven't really resolved, namely > sharing configuration information between various notmuch frontends. >

notmuch-vim doesn't respect notmuch config defaults

2014-10-02 Thread Ian Main
Sergei Shilovsky wrote: > I would suggest to use `notmuch config list` to get configuration > values in vim if possible > > Reproduction example follows: > > /home/sh> cat .notmuch-config > [new] > tags=new;inbox;unread > ignore= > > [search] > exclude_tags=deleted;spam > > [maildir] >

Re: [PATCH v3] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread Austin Clements
On Wed, 24 Sep 2014, "W. Trevor King" wrote: > On Wed, Sep 24, 2014 at 05:32:50PM -0400, Austin Clements wrote: >> + * If the caller is currently in an atomic section (there was a >> + * notmuch_database_begin_atomic without a matching >> + * notmuch_database_end_atomic), this will abort the atomi

[PATCH v4] lib: Simplify close and codify aborting atomic section

2014-10-02 Thread Austin Clements
From: Austin Clements In Xapian, closing a database implicitly aborts any outstanding transaction and commits changes. For historical reasons, notmuch_database_close had grown to almost, but not quite duplicate this behavior. Before closing the database, it would explicitly (and unnecessarily)

Re: notmuch-vim doesn't respect notmuch config defaults

2014-10-02 Thread David Bremner
Sergei Shilovsky writes: > I would suggest to use `notmuch config list` to get configuration > values in vim if possible I guess this is a general question we haven't really resolved, namely sharing configuration information between various notmuch frontends. .notmuch-config is really the config

notmuch-vim doesn't respect notmuch config defaults

2014-10-02 Thread Sergei Shilovsky
I would suggest to use `notmuch config list` to get configuration values in vim if possible Reproduction example follows: /home/sh> cat .notmuch-config [new] tags=new;inbox;unread ignore= [search] exclude_tags=deleted;spam [maildir] synchronize_flags=false /home/sh> notmuch config lis

[PATCH] VIM: Add better attachment support

2014-10-02 Thread Ian Main
This patch changes how the notmuch vim client supports attachments: - For each attachment an 'Attachment : ' is added to the header - You can then use 'e' to extract the attachment under the cursor or use it elsewhere to extract all attachments (the prior behavior) - You can use 'v' to 'view'

[PATCH] VIM: Add better attachment support

2014-10-02 Thread Ian Main
This patch changes how the notmuch vim client supports attachments: - For each attachment an 'Attachment : ' is added to the header - You can then use 'e' to extract the attachment under the cursor or use it elsewhere to extract all attachments (the prior behavior) - You can use 'v' to 'view'

[PATCH] Add default configuration values to the man page

2014-10-02 Thread Sergei Shilovsky
--- doc/man1/notmuch-config.rst | 18 ++ 1 file changed, 18 insertions(+) diff --git a/doc/man1/notmuch-config.rst b/doc/man1/notmuch-config.rst index 3c9a568..9de5534 100644 --- a/doc/man1/notmuch-config.rst +++ b/doc/man1/notmuch-config.rst @@ -49,19 +49,31 @@ The available conf