1 Return-Path: <tomi.ollila@iki.fi>
\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 3C84F431FBF
\r
6 for <notmuch@notmuchmail.org>; Sun, 19 Oct 2014 02:53:46 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]
\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 mrz72NNvojeF for <notmuch@notmuchmail.org>;
\r
16 Sun, 19 Oct 2014 02:53:39 -0700 (PDT)
\r
17 Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34])
\r
18 by olra.theworths.org (Postfix) with ESMTP id 0798B431FB6
\r
19 for <notmuch@notmuchmail.org>; Sun, 19 Oct 2014 02:53:39 -0700 (PDT)
\r
20 Received: from guru.guru-group.fi (localhost [IPv6:::1])
\r
21 by guru.guru-group.fi (Postfix) with ESMTP id B63CC10008C;
\r
22 Sun, 19 Oct 2014 12:53:19 +0300 (EEST)
\r
23 From: Tomi Ollila <tomi.ollila@iki.fi>
\r
24 To: Ian Main <imain@stemwinder.org>, notmuch@notmuchmail.org
\r
25 Subject: Re: [PATCH] VIM: Make an option to save sent mail locally
\r
26 In-Reply-To: <5433693499518_7e54e45e9424@ovo.mains.priv.notmuch>
\r
27 References: <1412617904-27252-1-git-send-email-imain@stemwinder.org>
\r
28 <1412619036-29203-1-git-send-email-imain@stemwinder.org>
\r
29 <m27g0dt5lk.fsf@guru.guru-group.fi>
\r
30 <5433693499518_7e54e45e9424@ovo.mains.priv.notmuch>
\r
31 User-Agent: Notmuch/0.18.1+130~ga61922f (http://notmuchmail.org) Emacs/24.3.1
\r
32 (x86_64-unknown-linux-gnu)
\r
33 X-Face: HhBM'cA~<r"^Xv\KRN0P{vn'Y"Kd;zg_y3S[4)KSN~s?O\"QPoL
\r
34 $[Xv_BD:i/F$WiEWax}R(MPS`^UaptOGD`*/=@\1lKoVa9tnrg0TW?"r7aRtgk[F
\r
35 !)g;OY^,BjTbr)Np:%c_o'jj,Z
\r
36 Date: Sun, 19 Oct 2014 12:53:19 +0300
\r
37 Message-ID: <m2mw8sbd2o.fsf@guru.guru-group.fi>
\r
39 Content-Type: text/plain
\r
40 X-BeenThere: notmuch@notmuchmail.org
\r
41 X-Mailman-Version: 2.1.13
\r
43 List-Id: "Use and development of the notmuch mail system."
\r
44 <notmuch.notmuchmail.org>
\r
45 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
46 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
47 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
48 List-Post: <mailto:notmuch@notmuchmail.org>
\r
49 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
50 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
51 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
52 X-List-Received-Date: Sun, 19 Oct 2014 09:53:46 -0000
\r
54 On Tue, Oct 07 2014, Ian Main <imain@stemwinder.org> wrote:
\r
56 > Tomi Ollila wrote:
\r
57 >> On Mon, Oct 06 2014, Ian Main <imain@stemwinder.org> wrote:
\r
59 >> > Add an option to use 'notmuch insert' to save your sent mail.
\r
62 >> > Add -inbox as well.
\r
64 >> > vim/notmuch.vim | 17 +++++++++++++++++
\r
65 >> > 1 file changed, 17 insertions(+)
\r
67 >> > diff --git a/vim/notmuch.vim b/vim/notmuch.vim
\r
68 >> > index 331e930..a9044c4 100644
\r
69 >> > --- a/vim/notmuch.vim
\r
70 >> > +++ b/vim/notmuch.vim
\r
71 >> > @@ -58,6 +58,7 @@ let s:notmuch_date_format_default = '%d.%m.%y'
\r
72 >> > let s:notmuch_datetime_format_default = '%d.%m.%y %H:%M:%S'
\r
73 >> > let s:notmuch_reader_default = 'mutt -f %s'
\r
74 >> > let s:notmuch_sendmail_default = 'sendmail'
\r
75 >> > +let s:notmuch_save_sent_locally_default = 1
\r
76 >> > let s:notmuch_folders_count_threads_default = 0
\r
78 >> > function! s:new_file_buffer(type, fname)
\r
79 >> > @@ -108,6 +109,18 @@ EOF
\r
84 >> AFAIU looks mmm. readable ;)
\r
87 >> > + if g:notmuch_save_sent_locally
\r
88 >> > + let out = system('cat ' . fname . ' | notmuch insert --create-folder --folder=Sent +sent -unread -inbox')
\r
90 >> as this is (looks like) shell invocation, this could be in format
\r
92 >> let out = system('notmuch insert --create-folder --folder=Sent +sent -unread -inbox < ' . fname)
\r
94 > You are right, that's better.
\r
98 >> let out = system('exec notmuch insert --create-folder --folder=Sent +sent -unread -inbox < ' . fname)
\r
100 >> (well, the latter would be out of the status quo)
\r
102 >> Ok, I looked a bit into the notmuch.vim -code, and noticed sometimes
\r
103 >> system() command lines use "notmuch" and sometimes g:notmuch_cmd
\r
104 >> -- I think the latter should be used in new code and the previous ones
\r
105 >> should be fixed.
\r
107 >> i.e. system ( g:notmuch_cmd . ' insert ... ' < . fname)
\r
109 >> Totally untested from my part...
\r
111 >> When the change alike this lands to the notmuch repository this needs NEWS
\r
112 >> item which informs that from now sent mails are notmuch-inserted to
\r
113 >> user's mail store (as this seems to be the default...) -- well, let's see
\r
114 >> that when there are real reviewers (i.e. those who are interested to and can
\r
117 > Also a good suggestion. From what I see they always use 'notmuch' straight up
\r
118 > which is probably a reasonable assumption. I do think the actual init code for
\r
119 > vim could have a few more checks, such as verifying that 'notmuch' is in $PATH
\r
122 > Thanks for the review!! I'll send out a new rev tomorrow - very tired
\r
125 I never seen the new rev... :D
\r