maintenance of notmuch ruby bindings

2014-05-15 Thread Ali Polatel
2014-05-15 0:59 GMT+03:00 Wael Nasreddine :
> David Bremner  writes:
>
>> Dear Ali;

Hello David,

>> Looking at the commit history, I noticed you haven't worked very much on
>> the notmuch ruby bindings in the last couple years.  That could be
>> because notmuch needs to be done, but if you've lost interest, maybe we
>> should pass on the torch to someone else?  I think Felipe, in copy,
>> would be willing to take that on. At the moment I guess his notmuch-mua
>> is the main consumer. Of course if your still willing/able, that's fine
>> too.

Honestly it's a good idea for me to step down as the maintainer.
I would still love to contribute when I have the time again.
Of course this does not require me to be the maintainer.
As far as I can tell Felipe would be a great fit.

Thanks for the great software.
It is always a pleasure to contribute :)


> I'll be willing to help maintaining it if you need more volunteers.
>
>>
>> d
>> ___
>> notmuch mailing list
>> notmuch at notmuchmail.org
>> http://notmuchmail.org/mailman/listinfo/notmuch
>
> --
>


Re: maintenance of notmuch ruby bindings

2014-05-15 Thread Ali Polatel
2014-05-15 0:59 GMT+03:00 Wael Nasreddine :
> David Bremner  writes:
>
>> Dear Ali;

Hello David,

>> Looking at the commit history, I noticed you haven't worked very much on
>> the notmuch ruby bindings in the last couple years.  That could be
>> because notmuch needs to be done, but if you've lost interest, maybe we
>> should pass on the torch to someone else?  I think Felipe, in copy,
>> would be willing to take that on. At the moment I guess his notmuch-mua
>> is the main consumer. Of course if your still willing/able, that's fine
>> too.

Honestly it's a good idea for me to step down as the maintainer.
I would still love to contribute when I have the time again.
Of course this does not require me to be the maintainer.
As far as I can tell Felipe would be a great fit.

Thanks for the great software.
It is always a pleasure to contribute :)


> I'll be willing to help maintaining it if you need more volunteers.
>
>>
>> d
>> ___
>> notmuch mailing list
>> notmuch@notmuchmail.org
>> http://notmuchmail.org/mailman/listinfo/notmuch
>
> --
>
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


maintenance of notmuch ruby bindings

2014-05-15 Thread David Bremner

Dear Ali;

Looking at the commit history, I noticed you haven't worked very much on
the notmuch ruby bindings in the last couple years.  That could be
because notmuch needs to be done, but if you've lost interest, maybe we
should pass on the torch to someone else?  I think Felipe, in copy,
would be willing to take that on. At the moment I guess his notmuch-mua
is the main consumer. Of course if your still willing/able, that's fine
too.

d


Re: maintenance of notmuch ruby bindings

2014-05-14 Thread Wael Nasreddine
David Bremner  writes:

> Dear Ali;
>
> Looking at the commit history, I noticed you haven't worked very much on
> the notmuch ruby bindings in the last couple years.  That could be
> because notmuch needs to be done, but if you've lost interest, maybe we
> should pass on the torch to someone else?  I think Felipe, in copy,
> would be willing to take that on. At the moment I guess his notmuch-mua
> is the main consumer. Of course if your still willing/able, that's fine
> too.

I'll be willing to help maintaining it if you need more volunteers.

>
> d
> ___
> notmuch mailing list
> notmuch@notmuchmail.org
> http://notmuchmail.org/mailman/listinfo/notmuch
-- 


pgpfZCzdKNvFq.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


maintenance of notmuch ruby bindings

2014-05-14 Thread Wael Nasreddine
David Bremner  writes:

> Dear Ali;
>
> Looking at the commit history, I noticed you haven't worked very much on
> the notmuch ruby bindings in the last couple years.  That could be
> because notmuch needs to be done, but if you've lost interest, maybe we
> should pass on the torch to someone else?  I think Felipe, in copy,
> would be willing to take that on. At the moment I guess his notmuch-mua
> is the main consumer. Of course if your still willing/able, that's fine
> too.

I'll be willing to help maintaining it if you need more volunteers.

>
> d
> ___
> notmuch mailing list
> notmuch at notmuchmail.org
> http://notmuchmail.org/mailman/listinfo/notmuch
-- next part --
-- 
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 180 bytes
Desc: not available
URL: 
<http://notmuchmail.org/pipermail/notmuch/attachments/20140514/e4152da3/attachment.pgp>


maintenance of notmuch ruby bindings

2014-05-14 Thread David Bremner

Dear Ali;

Looking at the commit history, I noticed you haven't worked very much on
the notmuch ruby bindings in the last couple years.  That could be
because notmuch needs to be done, but if you've lost interest, maybe we
should pass on the torch to someone else?  I think Felipe, in copy,
would be willing to take that on. At the moment I guess his notmuch-mua
is the main consumer. Of course if your still willing/able, that's fine
too.

d
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


Notmuch Ruby bindings

2010-11-09 Thread Rob Browning
Andreas Amann  writes:

> After a number of embarrassing mails I use the attached patch, which
> changes the default behaviour of "r" to "reply to sender only". Usual
> reply to everybody is "R". Maybe you prefer reversed binding?

At least in gnus:

 r - start reply to author
 R - start reply to author, including a copy of the original
 f - start reply to all
 F - start reply to all, including a copy of the original

I believe f/F probably respect Mail-Followup-To.

FWIW
-- 
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4


Re: Notmuch Ruby bindings

2010-11-09 Thread Rob Browning
Andreas Amann  writes:

> After a number of embarrassing mails I use the attached patch, which
> changes the default behaviour of "r" to "reply to sender only". Usual
> reply to everybody is "R". Maybe you prefer reversed binding?

At least in gnus:

 r - start reply to author
 R - start reply to author, including a copy of the original
 f - start reply to all
 F - start reply to all, including a copy of the original

I believe f/F probably respect Mail-Followup-To.

FWIW
-- 
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


Notmuch Ruby bindings

2010-11-08 Thread Andreas Amann
On Mon, 08 Nov 2010 10:02:31 -0800, Carl Worth  wrote:
> Now, where was that patch adding a "reply to sender only" binding... 
> 

After a number of embarrassing mails I use the attached patch, which
changes the default behaviour of "r" to "reply to sender only". Usual
reply to everybody is "R". Maybe you prefer reversed binding?


Andreas


-- next part --
A non-text attachment was scrubbed...
Name: 0001-Add-reply-to-sender-only-functionality.patch
Type: text/x-patch
Size: 5731 bytes
Desc: not available
URL: 



Re: Notmuch Ruby bindings

2010-11-08 Thread Andreas Amann
On Mon, 08 Nov 2010 10:02:31 -0800, Carl Worth  wrote:
> Now, where was that patch adding a "reply to sender only" binding... 
> 

After a number of embarrassing mails I use the attached patch, which
changes the default behaviour of "r" to "reply to sender only". Usual
reply to everybody is "R". Maybe you prefer reversed binding?


Andreas


Add reply to sender only functionality

This changes the default keybinding "r" in notmuch emacs interface to
mean "reply to sender only". This is an adapted version of a patch by
Michal Sojka.
---
 emacs/notmuch-mua.el  |2 +-
 emacs/notmuch-show.el |   10 --
 emacs/notmuch.el  |   12 ++--
 notmuch-reply.c   |9 +++--
 notmuch.1 |6 ++
 notmuch.c |3 +++
 6 files changed, 35 insertions(+), 7 deletions(-)

diff --git a/emacs/notmuch-mua.el b/emacs/notmuch-mua.el
index dc7b386..2cf846e 100644
--- a/emacs/notmuch-mua.el
+++ b/emacs/notmuch-mua.el
@@ -75,7 +75,7 @@ list."
 ;; really only that the headers come first followed by a blank
 ;; line and then the body.
 (with-temp-buffer
-  (call-process notmuch-command nil t nil "reply" query-string)
+  (apply 'call-process (append (list notmuch-command nil t nil "reply") query-string))
   (goto-char (point-min))
   (if (re-search-forward "^$" nil t)
 	  (save-excursion
diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
index 98a2fbc..b634b8d 100644
--- a/emacs/notmuch-show.el
+++ b/emacs/notmuch-show.el
@@ -563,7 +563,8 @@ function is used. "
 	(define-key map "s" 'notmuch-search)
 	(define-key map "m" 'notmuch-mua-mail)
 	(define-key map "f" 'notmuch-show-forward-message)
-	(define-key map "r" 'notmuch-show-reply)
+	(define-key map "R" 'notmuch-show-reply)
+	(define-key map "r" 'notmuch-show-reply-to-sender)
 	(define-key map "|" 'notmuch-show-pipe-message)
 	(define-key map "w" 'notmuch-show-save-attachments)
 	(define-key map "V" 'notmuch-show-view-raw-message)
@@ -870,7 +871,12 @@ any effects from previous calls to
 (defun notmuch-show-reply ()
   "Reply to the current message."
   (interactive)
-  (notmuch-mua-reply (notmuch-show-get-message-id)))
+  (notmuch-mua-reply (list (notmuch-show-get-message-id
+
+(defun notmuch-show-reply-to-sender ()
+  "Reply to the current message (only to the sender)."
+  (interactive)
+  (notmuch-mua-reply (list "--sender-only" (notmuch-show-get-message-id
 
 (defun notmuch-show-forward-message ()
   "Forward the current message."
diff --git a/emacs/notmuch.el b/emacs/notmuch.el
index 2a87ab9..8897d09 100644
--- a/emacs/notmuch.el
+++ b/emacs/notmuch.el
@@ -203,7 +203,8 @@ For a mouse binding, return nil."
 (define-key map ">" 'notmuch-search-last-thread)
 (define-key map "p" 'notmuch-search-previous-thread)
 (define-key map "n" 'notmuch-search-next-thread)
-(define-key map "r" 'notmuch-search-reply-to-thread)
+(define-key map "R" 'notmuch-search-reply-to-thread)
+(define-key map "r" 'notmuch-search-reply-to-thread-sender)
 (define-key map "m" 'notmuch-mua-mail)
 (define-key map "s" 'notmuch-search)
 (define-key map "o" 'notmuch-search-toggle-order)
@@ -427,7 +428,14 @@ Complete list of currently available key bindings:
   "Begin composing a reply to the entire current thread in a new buffer."
   (interactive)
   (let ((message-id (notmuch-search-find-thread-id)))
-(notmuch-mua-reply message-id)))
+(notmuch-mua-reply (list message-id
+
+(defun notmuch-search-reply-to-thread-sender ()
+  "Begin composing a reply to the sender only of the  current thread in a new buffer."
+  (interactive)
+  (let ((message-id (notmuch-search-find-thread-id)))
+(notmuch-mua-reply (list "--sender-only" message-id
+
 
 (defun notmuch-call-notmuch-process (&rest args)
   "Synchronously invoke \"notmuch\" with the given list of arguments.
diff --git a/notmuch-reply.c b/notmuch-reply.c
index 23d04b8..886157a 100644
--- a/notmuch-reply.c
+++ b/notmuch-reply.c
@@ -24,6 +24,8 @@
 #include "gmime-filter-reply.h"
 #include "gmime-filter-headers.h"
 
+static notmuch_bool_t sender_only = FALSE;
+
 static void
 reply_part_content (GMimeObject *part)
 {
@@ -272,6 +274,7 @@ add_recipients_from_message (GMimeMessage *reply,
 };
 const char *from_addr = NULL;
 unsigned int i;
+unsigned int max;
 
 /* Some mailing lists munge the Reply-To header despite it being A Bad
  * Thing, see http://www.unicom.com/pw/reply-to-harmful.html
@@ -288,8 +291,8 @@ add_recipients_from_message (GMimeMessage *reply,
 	reply_to_map[0].header = "from";
 	reply_to_map[0].fallback = NULL;
 }
-
-for (i = 0; i < ARRAY_SIZE (reply_to_map); i++) {
+max = sender_only ? 1 : ARRAY_SIZE (reply_to_map);
+for (i = 0; i < max; i++) {
 	const char *addr, *recipients;
 
 	recipients = notmuch_message_get_header (message,
@@ -595,6 +598,8 @@ notmuch_reply_command (void *ctx, int argc, char *argv[])
 		fprintf (stderr, "Invalid value for --format: %s\n", opt);

Re: Notmuch Ruby bindings

2010-11-08 Thread Carl Worth
On Mon, 08 Nov 2010 09:47:19 -0800, Carl Worth  wrote:
> Here are those instructions. Just reply to this message and send me a
> public ssh key, then I'll merge your ruby bindings to master, and set
> things up so that you can push any future changes.

Bah. I had intended to send that message only to Ali, and not to the
list.

Now, where was that patch adding a "reply to sender only" binding... 

-Carl

-- 
carl.d.wo...@intel.com


pgpIEuad98lJo.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


Notmuch Ruby bindings

2010-11-08 Thread Carl Worth
On Mon, 08 Nov 2010 09:47:19 -0800, Carl Worth  wrote:
> Here are those instructions. Just reply to this message and send me a
> public ssh key, then I'll merge your ruby bindings to master, and set
> things up so that you can push any future changes.

Bah. I had intended to send that message only to Ali, and not to the
list.

Now, where was that patch adding a "reply to sender only" binding... 

-Carl

-- 
carl.d.worth at intel.com
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: 



Re: Notmuch Ruby bindings

2010-11-08 Thread Carl Worth
On Mon, 08 Nov 2010 09:44:53 -0800, Carl Worth  wrote:
> I'm glad to see these implemented within the bindings directory of the
> notmuch source code. If you'd be interested, I'd be happy to host these
> bindings in the primary repository, (where you could just push changes
> directly). I'll send you separate instructions if you're interested in
> that.

Here are those instructions. Just reply to this message and send me a
public ssh key, then I'll merge your ruby bindings to master, and set
things up so that you can push any future changes.

Thanks,

-Carl

-- 
carl.d.wo...@intel.com


pgpBK04fepybj.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


Notmuch Ruby bindings

2010-11-08 Thread Carl Worth
On Mon, 08 Nov 2010 09:44:53 -0800, Carl Worth  wrote:
> I'm glad to see these implemented within the bindings directory of the
> notmuch source code. If you'd be interested, I'd be happy to host these
> bindings in the primary repository, (where you could just push changes
> directly). I'll send you separate instructions if you're interested in
> that.

Here are those instructions. Just reply to this message and send me a
public ssh key, then I'll merge your ruby bindings to master, and set
things up so that you can push any future changes.

Thanks,

-Carl

-- 
carl.d.worth at intel.com
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: 



Re: Notmuch Ruby bindings

2010-11-08 Thread Carl Worth
On Sat, 22 May 2010 10:26:52 +0300, Ali Polatel  wrote:
> I've written Ruby bindings for the notmuch library.

Hi, Ali.

Thanks so much for writing these bindings and sharing them with the
community! I'm sorry it has taken me so long before I've responded to
your message announcing these.

> - Clone the git url mentioned above and switch to the ruby branch.
> - Build the notmuch library
> - cd bindings/ruby

I'm glad to see these implemented within the bindings directory of the
notmuch source code. If you'd be interested, I'd be happy to host these
bindings in the primary repository, (where you could just push changes
directly). I'll send you separate instructions if you're interested in
that.

-Carl

-- 
carl.d.wo...@intel.com


pgpbnpNqt1WAg.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


Notmuch Ruby bindings

2010-11-08 Thread Carl Worth
On Sat, 22 May 2010 10:26:52 +0300, Ali Polatel  wrote:
> I've written Ruby bindings for the notmuch library.

Hi, Ali.

Thanks so much for writing these bindings and sharing them with the
community! I'm sorry it has taken me so long before I've responded to
your message announcing these.

> - Clone the git url mentioned above and switch to the ruby branch.
> - Build the notmuch library
> - cd bindings/ruby

I'm glad to see these implemented within the bindings directory of the
notmuch source code. If you'd be interested, I'd be happy to host these
bindings in the primary repository, (where you could just push changes
directly). I'll send you separate instructions if you're interested in
that.

-Carl

-- 
carl.d.worth at intel.com
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: 



Notmuch Ruby bindings

2010-05-22 Thread Ali Polatel

Hey all,
I've written Ruby bindings for the notmuch library.

Here are related links:
Gitweb: http://github.com/alip/notmuch/tree/ruby
Git: git://github.com/alip/notmuch.git (branch ruby)
API documentation: http://dev.exherbo.org/~alip/notmuch/ruby/

Building is simple:
- Clone the git url mentioned above and switch to the ruby branch.
- Build the notmuch library
- cd bindings/ruby
- ruby extconf.rb
- make

This is written in pure C, unlike Python bindings, which uses
ctypes. This means it should be a bit faster but possibly more buggy,
especially the garbage collection routines. I've tried hard to make
Ruby's GC play nice with notmuch's talloc based memory allocation but I
can't be sure if it's bug-free.

I haven't written any examples yet but the API documentation should be
clear enough for one to understand and dive in.

As usual, any comments, patches welcome.

-- 
Regards,
Ali Polatel
-- next part --
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: 



Notmuch Ruby bindings

2010-05-22 Thread Ali Polatel

Hey all,
I've written Ruby bindings for the notmuch library.

Here are related links:
Gitweb: http://github.com/alip/notmuch/tree/ruby
Git: git://github.com/alip/notmuch.git (branch ruby)
API documentation: http://dev.exherbo.org/~alip/notmuch/ruby/

Building is simple:
- Clone the git url mentioned above and switch to the ruby branch.
- Build the notmuch library
- cd bindings/ruby
- ruby extconf.rb
- make

This is written in pure C, unlike Python bindings, which uses
ctypes. This means it should be a bit faster but possibly more buggy,
especially the garbage collection routines. I've tried hard to make
Ruby's GC play nice with notmuch's talloc based memory allocation but I
can't be sure if it's bug-free.

I haven't written any examples yet but the API documentation should be
clear enough for one to understand and dive in.

As usual, any comments, patches welcome.

-- 
Regards,
Ali Polatel


pgpqp51SVozri.pgp
Description: PGP signature
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch