diff --git a/init.el b/init.el index 69cf0be..c525237 100644 --- a/init.el +++ b/init.el @@ -1205,19 +1205,6 @@ are assumed to be of the form *.crt." (add-hook 'hy-mode-hook 'lispy-mode) (add-hook 'hy-mode-hook 'inferior-lisp))) -(defun org-babel-execute:hy (body params) - ;; http://kitchingroup.cheme.cmu.edu/blog/2016/03/30/OMG-A-Lisp-that-runs-python/ - "Execute hy code BODY with parameters PARAMS." - (ignore params) - (let* ((temporary-file-directory ".") - (tempfile (make-temp-file "hy-"))) - (with-temp-file tempfile - (insert body)) - (unwind-protect - (shell-command-to-string - (format "hy %s" tempfile)) - (delete-file tempfile)))) - ;; * TeX diff --git a/site-lisp/db-org.el b/site-lisp/db-org.el index e50e8d1..3855157 100644 --- a/site-lisp/db-org.el +++ b/site-lisp/db-org.el @@ -886,6 +886,22 @@ Current Task: %`org-clock-current-task; " (when (package-installed-p 'org-download) (use-package org-download)) + +;;; Babel + +(defun org-babel-execute:hy (body params) + ;; http://kitchingroup.cheme.cmu.edu/blog/2016/03/30/OMG-A-Lisp-that-runs-python/ + "Execute hy code BODY with parameters PARAMS." + (ignore params) + (let* ((temporary-file-directory ".") + (tempfile (make-temp-file "hy-"))) + (with-temp-file tempfile + (insert body)) + (unwind-protect + (shell-command-to-string + (format "hy %s" tempfile)) + (delete-file tempfile)))) + ;;; End