From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Goaziou Subject: Re: Library of Babel confusion Date: Tue, 03 Apr 2018 22:44:00 +0200 Message-ID: <87r2nwvx4f.fsf@nicolasgoaziou.fr> References: Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:38053) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f3qWw-0002HK-Ju for emacs-orgmode@gnu.org; Wed, 04 Apr 2018 18:05:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f3qWs-0000ou-Gp for emacs-orgmode@gnu.org; Wed, 04 Apr 2018 18:05:22 -0400 Received: from relay1-d.mail.gandi.net ([217.70.183.193]:34213) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1f3qWs-0000na-9o for emacs-orgmode@gnu.org; Wed, 04 Apr 2018 18:05:18 -0400 In-Reply-To: (Lawrence Bottorff's message of "Tue, 3 Apr 2018 16:31:57 -0400") 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" To: Lawrence Bottorff Cc: emacs-orgmode Mailinglist Lawrence Bottorff writes: > I've been trying to grok LOB again. So I've cloned the worg git and > library-of-babel.el is one of the files. org-babel-lob-injest didn't > work, What doesn't work? You call `org-babel-lob-ingest', specify a file, and it stores all source code blocks in the file for later use. > Now, in my org file I put this: > > #+lob: write(file="jsontest") This should be #+call: write(...) > > and try C-c C-c on it. Nothing. My minibuffer says "local setup has been > refreshed". How does one use, call a LOB function? Also, while I'm > demonstrating my rank noobian-ness, I try this: > > #+name: myelsquare > #+header: :var x=0 > > #+begin_src emacs-lisp > (* x x) > #+end_src > > #+call: myelsquare(x=6) > > #+RESULTS: : 36 > > but this results in > > #+name: myelsquare > #+header: :var x=0 > > #+begin_src emacs-lisp > (defun myelsquare (x) > (* x x)) > #+end_src > > #+call: myelsquare(x=6) > > #+RESULTS: > : myelsquare2 > > After a #+call:... I use C-c C-c to evaluate it. What am I missing > here? Your second block defines a function, but doesn't return its results. "#+call: myelsquare(...)" expects to find a block named "myelsquare", not an Elisp function named "myelsquare". Regards, -- Nicolas Goaziou