1 Return-Path: <dmitry.kurochkin@gmail.com>
\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 6CACD429E21
\r
6 for <notmuch@notmuchmail.org>; Thu, 17 Nov 2011 03:13:58 -0800 (PST)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=-0.799 tagged_above=-999 required=5
\r
12 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,
\r
13 FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled
\r
14 Received: from olra.theworths.org ([127.0.0.1])
\r
15 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
16 with ESMTP id jXNsPAvr7heT for <notmuch@notmuchmail.org>;
\r
17 Thu, 17 Nov 2011 03:13:57 -0800 (PST)
\r
18 Received: from mail-bw0-f53.google.com (mail-bw0-f53.google.com
\r
19 [209.85.214.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits))
\r
20 (No client certificate requested)
\r
21 by olra.theworths.org (Postfix) with ESMTPS id 94D65431FD0
\r
22 for <notmuch@notmuchmail.org>; Thu, 17 Nov 2011 03:13:57 -0800 (PST)
\r
23 Received: by bkaq10 with SMTP id q10so1977075bka.26
\r
24 for <notmuch@notmuchmail.org>; Thu, 17 Nov 2011 03:13:56 -0800 (PST)
\r
25 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma;
\r
26 h=from:to:subject:in-reply-to:references:user-agent:date:message-id
\r
27 :mime-version:content-type;
\r
28 bh=1FGcI3i0GtgV7hEeqjMGLeuCZADCaGyPPdRGTsudFUQ=;
\r
29 b=J9X5VL1pQ8oSJSE+E+Ol7+7NmT+ab2AlbcD7rH78PRiHt/Bhv5vqaQzRKDtNNm+YMA
\r
30 lCl2edUl/CwWShCh0IKGmchITTNY2HX3+ZqgCQ3eI4DysZaQqxaJDiPr36D4UTeaF2oC
\r
31 GkUBkd41VJUvuXmmIaDCXiipb4CqeJkjPXB70=
\r
32 Received: by 10.205.127.68 with SMTP id gz4mr32869513bkc.17.1321528436101;
\r
33 Thu, 17 Nov 2011 03:13:56 -0800 (PST)
\r
34 Received: from localhost ([91.144.186.21])
\r
35 by mx.google.com with ESMTPS id n19sm9154471bka.0.2011.11.17.03.13.55
\r
36 (version=TLSv1/SSLv3 cipher=OTHER);
\r
37 Thu, 17 Nov 2011 03:13:55 -0800 (PST)
\r
38 From: Dmitry Kurochkin <dmitry.kurochkin@gmail.com>
\r
39 To: Tomi Ollila <tomi.ollila@iki.fi>, notmuch@notmuchmail.org
\r
40 Subject: Re: [PATCH 8/9] test: check if emacs is available in the beginning of
\r
42 In-Reply-To: <yf67h2zgk3b.fsf@taco2.nixu.fi>
\r
43 References: <1321494986-18998-1-git-send-email-dmitry.kurochkin@gmail.com>
\r
44 <1321494986-18998-9-git-send-email-dmitry.kurochkin@gmail.com>
\r
45 <yf67h2zgk3b.fsf@taco2.nixu.fi>
\r
46 User-Agent: Notmuch/0.10_rc1+9~g8270095 (http://notmuchmail.org) Emacs/23.3.1
\r
47 (x86_64-pc-linux-gnu)
\r
48 Date: Thu, 17 Nov 2011 15:13:40 +0400
\r
49 Message-ID: <87k46zngrf.fsf@gmail.com>
\r
51 Content-Type: text/plain; charset=us-ascii
\r
52 X-BeenThere: notmuch@notmuchmail.org
\r
53 X-Mailman-Version: 2.1.13
\r
55 List-Id: "Use and development of the notmuch mail system."
\r
56 <notmuch.notmuchmail.org>
\r
57 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
58 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
59 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
60 List-Post: <mailto:notmuch@notmuchmail.org>
\r
61 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
62 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
63 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
64 X-List-Received-Date: Thu, 17 Nov 2011 11:13:58 -0000
\r
66 On Thu, 17 Nov 2011 11:43:36 +0200, Tomi Ollila <tomi.ollila@iki.fi> wrote:
\r
67 > On Thu, 17 Nov 2011 05:56:25 +0400, Dmitry Kurochkin <dmitry.kurochkin@gmail.com> wrote:
\r
68 > > Unfortunately, this is needed to avoid the emacs waiting loop.
\r
71 > > test/test-lib.sh | 4 ++++
\r
72 > > 1 files changed, 4 insertions(+), 0 deletions(-)
\r
74 > [ context reduced ]
\r
76 > > diff --git a/test/test-lib.sh b/test/test-lib.sh
\r
77 > > index 840c86c..5bd5bd6 100755
\r
78 > > --- a/test/test-lib.sh
\r
79 > > +++ b/test/test-lib.sh
\r
81 > I have to patch the full set to my clone of the repo and do
\r
82 > fuller review, but until that...
\r
85 > > + # test dependencies beforehand to avoid the waiting loop below
\r
86 > > + which emacs >/dev/null || emacs || return
\r
87 > > + which emacsclient >/dev/null || emacsclient || return
\r
90 > If emacs not found using which (what happened to hash), then try
\r
91 > to execute emacs (??) and if that fails return.
\r
93 > Same thing with emacsclient.
\r
95 > In case of emacs: DISPLAY set, TERM=dumb -- emacs starts interactively
\r
96 > on my desktop; grep DISPLAY test/* yields nothing. (maybe we should unset
\r
97 > DISPLAY for tests ?). And, if DISPLAY unset, emacs exits with nonzero
\r
98 > value, making || return happen anyway.
\r
100 > ... and this is tested every time test_emacs() is executed...
\r
103 Either you did not apply other patches, or I made some stupid mistake.
\r
105 I am not very happy with the above lines. They feel hackish. Perhaps
\r
106 others would suggest something better.
\r
108 Here is a more detailed explanation of what they do (or should do):
\r
110 which emacs || # check that emacs binary exists (hash would succeed
\r
112 emacs || # if the binary does not exist, run the "replacement"
\r
113 # function which would register the missing dependency
\r
114 return # and return with an error
\r
119 > > if [ -z "$EMACS_SERVER" ]; then
\r
120 > > server_name="notmuch-test-suite-$$"
\r