From mboxrd@z Thu Jan 1 00:00:00 1970 From: Aaron Ecay Subject: Re: babel question: how to detect the REPL has finished replying Date: Thu, 11 Feb 2016 19:57:29 +0000 Message-ID: <87mvr7ow9i.fsf@gmail.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:55320) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aTxMu-0007VO-MA for emacs-orgmode@gnu.org; Thu, 11 Feb 2016 14:57:37 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aTxMq-000764-IT for emacs-orgmode@gnu.org; Thu, 11 Feb 2016 14:57:36 -0500 Received: from mail-wm0-x22e.google.com ([2a00:1450:400c:c09::22e]:34336) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aTxMq-00075s-Bc for emacs-orgmode@gnu.org; Thu, 11 Feb 2016 14:57:32 -0500 Received: by mail-wm0-x22e.google.com with SMTP id 128so36005439wmz.1 for ; Thu, 11 Feb 2016 11:57:31 -0800 (PST) In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Alan Schmitt Cc: orgmode Hi Alan, Other backends send an unlikely string literal to the interpreter as the last command, which will be echoed back verbatim. The code detects the presence of this string in the output stream, and thus knows that the interaction has finished. Check out the =E2=80=98org-babel-comint-with-out= put=E2=80=99 macro for the implementation. (This is the usual function of the org-babel-coq-eoe variable that your last patch deleted. It was probably cargo-culted in from another backend and never properly implemented.) Hope this is helpful, --=20 Aaron Ecay