[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Library of Babel confusion
From: |
Nicolas Goaziou |
Subject: |
Re: [O] Library of Babel confusion |
Date: |
Tue, 03 Apr 2018 22:44:00 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) |
Lawrence Bottorff <address@hidden> 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
- [O] Library of Babel confusion, Lawrence Bottorff, 2018/04/03
- Re: [O] Library of Babel confusion, Berry, Charles, 2018/04/03
- Re: [O] Library of Babel confusion, Lawrence Bottorff, 2018/04/06
- Re: [O] Library of Babel confusion, Thomas S. Dye, 2018/04/06
- Re: [O] Library of Babel confusion, Berry, Charles, 2018/04/06
- Re: [O] Library of Babel confusion, Lawrence Bottorff, 2018/04/10
- Re: [O] Library of Babel confusion, Thomas S. Dye, 2018/04/11
- Re: [O] Library of Babel confusion, Lawrence Bottorff, 2018/04/11
- Re: [O] Library of Babel confusion, Berry, Charles, 2018/04/11
- Re: [O] Library of Babel confusion, Thomas S. Dye, 2018/04/11
Re: [O] Library of Babel confusion,
Nicolas Goaziou <=