From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id A85F9431FBC for ; Fri, 3 Oct 2014 11:41:30 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_NONE=-0.0001] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id guVlFOMdp+5l for ; Fri, 3 Oct 2014 11:41:23 -0700 (PDT) Received: from cmta18.telus.net (cmta18.telus.net [209.171.16.91]) by olra.theworths.org (Postfix) with ESMTP id 67ACC431FB6 for ; Fri, 3 Oct 2014 11:41:23 -0700 (PDT) Received: from ovo.mains.priv ([207.102.88.62]) by cmta18.telus.net with TELUS id yihM1o00c1LiWEf01ihMB4; Fri, 03 Oct 2014 12:41:22 -0600 X-Authority-Analysis: v=2.0 cv=GdvJa3rL c=1 sm=2 a=EcQDfIwDZEqJA1f7rVUV8Q==:17 a=S-IsBHyFrF4A:10 a=IkcTkHD0fZMA:10 a=tsa3CZZnAAAA:8 a=9IXG43mSqOdJ_MyTbwwA:9 a=QEXdDO2ut3YA:10 a=P87eogJZi2UA:10 a=EcQDfIwDZEqJA1f7rVUV8Q==:117 X-Telus-Outbound-IP: 207.102.88.62 Received: from ovo.mains.priv (localhost.localdomain [127.0.0.1]) by ovo.mains.priv (8.14.8/8.14.8) with ESMTP id s93IfD6T020357; Fri, 3 Oct 2014 11:41:14 -0700 Received: (from imain@localhost) by ovo.mains.priv (8.14.8/8.14.8/Submit) id s93IfCT9020356; Fri, 3 Oct 2014 11:41:12 -0700 X-Authentication-Warning: ovo.mains.priv: imain set sender to imain@redhat.com using -f Date: Fri, 03 Oct 2014 11:41:12 -0700 From: Ian Main To: David Bremner , David Bremner , notmuch@notmuchmail.org Message-ID: <542eedc8cb635_ed1ddfe8cd0@ovo.mains.priv.notmuch> In-Reply-To: <87r3ypr6cm.fsf@maritornes.cs.unb.ca> References: <1412286796-27479-1-git-send-email-imain@stemwinder.org> <1412293635-31273-1-git-send-email-imain@stemwinder.org> <87r3ypr6cm.fsf@maritornes.cs.unb.ca> Subject: Re: [PATCH v2] VIM: Use notmuch CLI for config Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 03 Oct 2014 18:41:30 -0000 David Bremner wrote: > 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 notice there is not really any error handling; > OTOH, as far as I can read Ruby, there is not any in the previous > version either. Technically, this does add a dependency of the vim > client on the CLI that did not exist before. Personally I don't find > this onerous (even notmuch-vim users need "notmuch new", except in > rather unusual circumstances.). > > I'd like feedback/testing from actual vim interface users before > merging. I am actually just following suit on what was already being done. The Vim client was already calling out to notmuch CLI for other things, eg: system "notmuch show --format=mbox id:#{m.message_id} > #{mbox} && #{cmd}" Is used to save the email for display in another program. Also with no error checking. I think basically we are relying on rubys exception handling to display errors to the user.. not the best idea but it is functional. I could add a check for 'notmuch' binary.. especially there because loading the config is the first thing that is done on startup. Ian