emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: execute src block during export (Re: Worg HTML export problem?)


From: Thomas S. Dye
Subject: Re: execute src block during export (Re: Worg HTML export problem?)
Date: Thu, 11 Nov 2021 07:24:04 -1000
User-agent: mu4e 1.2.0; emacs 27.1

Aloha Max,

Max Nikulin <manikulin@gmail.com> writes:

On 11/11/2021 04:24, Thomas S. Dye wrote:
Max Nikulin writes:
On 08/11/2021 05:46, Thomas S. Dye wrote:
to fail, but AFAICT ob-doc-org.org doesn't have this affliction--it exports
locally.

Have you tried to export it from "emacs -Q -L /path/to/org-mode/lisp"? I think, you just have "org" in customized "org-babel-load-languages".

I've likely made some other error, but I don't have clue what it might be.
I don't know how to debug this.  Can someone help, please?

https://builds.sr.ht/~bzg/job/623225

[exporting] org-contrib/babel/languages/ob-doc-org.org
No org-babel-execute function for org!

However I do not see explicit load/require for particular language in sibling
files. I expected something like

#+begin_src emacs-lisp :exports none
  (require 'ob-org)
#+end_src
Thanks for looking into this.
Is the problem something I can fix in ob-doc-org.org? Or, does it have to do with the configuration at sr.ht?

All settings are in .build.yaml and publish.sh (lisp) file.

Sorry, I have missed the following code in your file

#+begin_src emacs-lisp
  (org-babel-do-load-languages
   'org-babel-load-languages
   '((org . t)))
#+end_src

I am unsure whether it should work in this form or it worked earlier, but on main branch it is not executed during export. If I change first line to the
following, the block is executed during export:

#+begin_src emacs-lisp :results value none :exports results

My minimal example:

Test

#+begin_src emacs-lisp :results value none :exports results
   (org-babel-do-load-languages
    'org-babel-load-languages
    '((org . t)))
#+end_src

#+name: org-hello
#+begin_src org :var hello="World"
  Hello, $hello!
#+end_src

#+begin_src elisp :var x=org-hello[](hello="Org") :exports both
  (print x)
#+end_src

Thanks!

The original problem is likely due to the default header arguments in ob-org.el, which are unusual.

If I export both, then all is well.

#+begin_src emacs-lisp :results value none :exports both
 (org-babel-do-load-languages
  'org-babel-load-languages
  '((org . t)))
#+end_src

All the best,
Tom
--
Thomas S. Dye
https://tsdye.online/tsdye



reply via email to

[Prev in Thread] Current Thread [Next in Thread]