--- /dev/null
+Return-Path: <teythoon@jade-hamburg.de>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+ by olra.theworths.org (Postfix) with ESMTP id 98463431FBF\r
+ for <notmuch@notmuchmail.org>; Tue, 21 May 2013 12:56:25 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0.001\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0.001 tagged_above=-999 required=5\r
+ tests=[UNPARSEABLE_RELAY=0.001] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+ by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+ with ESMTP id pXg9pIAMqO3X for <notmuch@notmuchmail.org>;\r
+ Tue, 21 May 2013 12:56:18 -0700 (PDT)\r
+Received: from mail.cryptobitch.de (cryptobitch.de [88.198.7.68])\r
+ (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))\r
+ (No client certificate requested)\r
+ by olra.theworths.org (Postfix) with ESMTPS id EED75431FB6\r
+ for <notmuch@notmuchmail.org>; Tue, 21 May 2013 12:56:17 -0700 (PDT)\r
+Received: from mail.jade-hamburg.de (mail.jade-hamburg.de [85.183.11.228])\r
+ (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))\r
+ (No client certificate requested)\r
+ by mail.cryptobitch.de (Postfix) with ESMTPSA id 36FEA62E0E6\r
+ for <notmuch@notmuchmail.org>; Tue, 21 May 2013 21:55:55 +0200 (CEST)\r
+Received: by mail.jade-hamburg.de (Postfix, from userid 401)\r
+ id C100EDF2A2; Tue, 21 May 2013 21:55:52 +0200 (CEST)\r
+Received: from thinkbox.jade-hamburg.de (unknown\r
+ [IPv6:fe80::213:e8ff:fe51:7a89%br0])\r
+ (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits))\r
+ (No client certificate requested) (Authenticated sender: teythoon)\r
+ by mail.jade-hamburg.de (Postfix) with ESMTPSA id BC53CDF28B;\r
+ Tue, 21 May 2013 21:55:51 +0200 (CEST)\r
+Received: from teythoon by thinkbox.jade-hamburg.de with local (Exim 4.80)\r
+ (envelope-from <teythoon@thinkbox.jade-hamburg.de>)\r
+ id 1Uesf0-00031b-7y; Tue, 21 May 2013 21:55:50 +0200\r
+Content-Type: text/plain; charset="utf-8"\r
+MIME-Version: 1.0\r
+Content-Transfer-Encoding: quoted-printable\r
+To: Tomi Ollila <tomi.ollila@iki.fi>, notmuch@notmuchmail.org\r
+From: Justus Winter <4winter@informatik.uni-hamburg.de>\r
+In-Reply-To: <1369161750-12342-1-git-send-email-tomi.ollila@iki.fi>\r
+References: <1369161750-12342-1-git-send-email-tomi.ollila@iki.fi>\r
+Message-ID: <20130521195549.6550.53636@thinkbox.jade-hamburg.de>\r
+User-Agent: alot/0.3.3+\r
+Subject: Re: [RFC PATCH 1/1] add --stderr option\r
+Date: Tue, 21 May 2013 21:55:49 +0200\r
+Cc: tomi.ollila@iki.fi\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+ <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Tue, 21 May 2013 19:56:25 -0000\r
+\r
+Quoting Tomi Ollila (2013-05-21 20:42:30)\r
+> ---\r
+> =\r
+\r
+> Note quickly written untested code (but compiles!), just to show an idea.=\r
+..\r
+> =\r
+\r
+> This implements (i hope) curl(1) --stderr option in notmuch(1):\r
+> =\r
+\r
+> --stderr <file>\r
+> Redirect all writes to stderr to the specified file instea=\r
+d. If\r
+> the file name is a plain '-', it is instead written to stdo=\r
+ut.\r
+> =\r
+\r
+> This would be useful in emacs interface.\r
+\r
+Hm, shouldn't it be possible to bind a pipe(2) to stderr instead? I\r
+mean in the process of running the notmuch binary (i.e. somewhere\r
+along the lines of fork and exec)?\r
+\r
+I've implemented this for alot, which does not use the binary but\r
+directly calls into libnotmuch, but does so in a helper process. Said\r
+helper has a pipe(2) on stderr and the alot process reads from it and\r
+turns any line into a log message.\r
+\r
+Justus\r