From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nick Dokos Subject: Re: Babel more verbose? Date: Tue, 02 Sep 2014 23:58:25 -0400 Message-ID: <877g1lmk2m.fsf@alphaville.dokosmarshall.org> References: <878um2dqdw.fsf@alphaville.bos.redhat.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37500) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XP1iZ-0000Vs-4F for emacs-orgmode@gnu.org; Tue, 02 Sep 2014 23:58:52 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XP1iU-0002WR-3k for emacs-orgmode@gnu.org; Tue, 02 Sep 2014 23:58:47 -0400 Received: from plane.gmane.org ([80.91.229.3]:33732) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XP1iT-0002WH-Tg for emacs-orgmode@gnu.org; Tue, 02 Sep 2014 23:58:42 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1XP1iQ-0002qJ-BE for emacs-orgmode@gnu.org; Wed, 03 Sep 2014 05:58:38 +0200 Received: from pool-108-20-41-17.bstnma.fios.verizon.net ([108.20.41.17]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 03 Sep 2014 05:58:38 +0200 Received: from ndokos by pool-108-20-41-17.bstnma.fios.verizon.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 03 Sep 2014 05:58:38 +0200 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: emacs-orgmode@gnu.org John Kitchin writes: > I found a message is not sufficient because I get another message from > running the code block that looks like: > > Wrote > /var/folders/5q/lllv2yf95hg_n6h6kjttbmdw0000gn/T/babel-27354lYd/ob-input-27354uxF > > and it obscures the first message so you cannot tell what is happening. > Right - that seems to be quite accidental though: it is done by write-region in ob-eval.el:org-babel--shell-command-on-region when it writes the input file, before it is passed to the shell for execution; hardly a significant milestone. I wonder if that call should be changed to suppress the message, something like (write-region start end input-file nil 'no-message) quite apart from the problem at hand. -- Nick >>> Try this: >>> >>> #+BEGIN_SRC emacs-lisp >>> (defadvice org-babel-execute-src-block (around progress nil activate) >>> "create a buffer indicating what is running" >>> (let ((code-block (org-element-property :name (org-element-at-point))) >>> (cb (current-buffer))) >>> (split-window-below) >>> (other-window 1) >>> (switch-to-buffer "*My Babel*") >>> (insert (format "Running %s" code-block)) >>> (other-window 1) >>> ad-do-it >>> (kill-buffer "*My Babel*") >>> (delete-other-windows))) >>> #+END_SRC >>> >>> It will mess with your windows a bit, but it does what you want I think. >>> >> >> Wouldn't a (message (format "Running %s" code-block)) be enough? >> That would avoid all the window munging. >> >>> >>> Gary Oberbrunner writes: >>> >>>> I have an org-mode babel program/document that takes about half an >>>> hour to run (end result is a LaTeX or HTML doc with figures). It's a >>>> mix of SQL and python. (The SQL is the slow part.) I'd really like it >>>> if org-mode could tell me, while it's running, which named block it's >>>> processing. Is there anything like that available? An option perhaps? >> >> -- >> Nick >> >> >> -- Nick