mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-08-26 14:02:55 +00:00
Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode
This commit is contained in:
commit
353366beb7
|
@ -230,15 +230,13 @@ or nil if \"none\" is specified"
|
|||
'replace)
|
||||
(buffer-string)))
|
||||
(value
|
||||
(let ((tmp-src-file (make-temp-file "clojure_babel_input_"))
|
||||
(tmp-results-file (make-temp-file "clojure_babel_results_")))
|
||||
(with-temp-file tmp-src-file
|
||||
(insert (format org-babel-clojure-wrapper-method body tmp-results-file tmp-results-file)))
|
||||
(shell-command
|
||||
(format "%s %s" (mapconcat #'identity (org-babel-clojure-babel-clojure-cmd) " ")
|
||||
tmp-src-file))
|
||||
(let ((tmp-results-file (make-temp-file "clojure_babel_results_")))
|
||||
(with-temp-buffer
|
||||
(insert (format org-babel-clojure-wrapper-method body tmp-results-file tmp-results-file))
|
||||
(shell-command-on-region (point-min) (point-max)
|
||||
(mapconcat #'identity (org-babel-clojure-babel-clojure-cmd) " ")))
|
||||
(org-babel-clojure-table-or-string
|
||||
(with-temp-buffer (insert-file-contents tmp-results-file) (buffer-string))))))))
|
||||
(with-temp-buffer (insert-file-contents (org-babel-maybe-remote-file tmp-results-file)) (buffer-string))))))))
|
||||
|
||||
(defun org-babel-clojure-evaluate-session (buffer body &optional result-type)
|
||||
"Evaluate the body in the context of a clojure session"
|
||||
|
|
|
@ -115,10 +115,7 @@ last statement in BODY, as elisp."
|
|||
tmp-file))
|
||||
;; (message "buffer=%s" (buffer-string)) ;; debugging
|
||||
(shell-command-on-region (point-min) (point-max) "perl"))
|
||||
(let ((raw (with-temp-buffer (insert-file-contents tmp-file) (buffer-string))))
|
||||
(if (or (member "code" result-params) (member "pp" result-params))
|
||||
raw
|
||||
(org-babel-import-elisp-from-file tmp-file)))))))
|
||||
(org-babel-import-elisp-from-file (org-babel-maybe-remote-file tmp-file))))))
|
||||
;; comint session evaluation
|
||||
(error "Sessions are not supported for Perl.")))
|
||||
|
||||
|
|
Loading…
Reference in a new issue