emacs-orgmode
[Top][All Lists]
Advanced

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

[PATCH] before emit an error message, try to load the babel language


From: lin Sun
Subject: [PATCH] before emit an error message, try to load the babel language
Date: Sat, 22 Apr 2023 07:21:45 +0000

Hi,
The function `org-babel-execute-src-block' will emit an error message
if the language is not loaded.

Before the error message, the patch will give a try to load the
associated babel language.

Why does the language exist in the `lang org-babel-load-languages' but
not be loaded?
Because the `org-babel-load-languages' are defined as a customer
variable with  :set 'org-babel-do-load-languages,  the ":set" function
can only be triggered with function `custom-set-variables`.
While setq/cl-pushnew `org-babel-load-languages' won't trigger the
`:set' function, then the error message will be displayed if I run the
code in the org file.

Please help review that patch. Thanks. Regards

Attachment: 0001-lisp-ob-core.el-load-lang-in-org-babel-execute-src-b.patch
Description: Text Data


reply via email to

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