babel: more compiler satisfaction
This commit is contained in:
parent
b9a8df9d1c
commit
0e939a7df5
|
@ -31,6 +31,15 @@
|
|||
;;; Code:
|
||||
(require 'ob)
|
||||
(require 'shell)
|
||||
(eval-when-compile
|
||||
(require 'cl))
|
||||
|
||||
(defun-function org-babel-ref-variables "ob-ref" (params))
|
||||
(defun-function org-babel-comint-in-buffer "ob-comint" (buffer &rest body))
|
||||
(defun-function org-babel-comint-wait-for-output "ob-comint" (buffer))
|
||||
(defun-function org-babel-comint-buffer-livep "ob-comint" (buffer))
|
||||
(defun-function org-babel-comint-with-output "ob-comint" (meta &rest body))
|
||||
(defun-function orgtbl-to-generic "org-table" (table params))
|
||||
|
||||
(org-babel-add-interpreter "sh")
|
||||
|
||||
|
|
|
@ -194,6 +194,7 @@ code block respecting the value of the :exports header argument."
|
|||
"\n\n"
|
||||
(org-babel-exp-results info type))))))
|
||||
|
||||
(defvar backend)
|
||||
(defun org-babel-exp-code (info type)
|
||||
"Return the code the current code block in a manner suitable
|
||||
for exportation by org-mode. This function is called by
|
||||
|
@ -229,7 +230,7 @@ evaluated."
|
|||
((eq backend 'html)
|
||||
(format "\n#+HTML: <label class=\"org-src-name\">%s</label>\n"
|
||||
call-line))
|
||||
((t (format ": %s\n" call-line)))))))))
|
||||
((format ": %s\n" call-line))))))))
|
||||
|
||||
(defun org-babel-exp-results (info type &optional silent)
|
||||
"Return the results of the current code block in a manner
|
||||
|
|
|
@ -105,7 +105,10 @@ return nil."
|
|||
;; if ref is indexed grab the indices -- beware nested indicies
|
||||
(when (and (string-match "\\[\\(.+\\)\\]" ref)
|
||||
(let ((str (substring ref 0 (match-beginning 0))))
|
||||
(= (count ?( str) (count ?) str))))
|
||||
(= (length (org-remove-if-not
|
||||
(lambda (el) (equal ?( el)) (string-to-list "((eric))")))
|
||||
(length (org-remove-if-not
|
||||
(lambda (el) (equal ?) el)) (string-to-list "((eric))"))))))
|
||||
(setq index (match-string 1 ref))
|
||||
(setq ref (substring ref 0 (match-beginning 0))))
|
||||
;; assign any arguments to pass to source block
|
||||
|
|
|
@ -55,7 +55,7 @@ org-mode formatted FILE. This function will first export the
|
|||
source code using `org-babel-tangle' and then load the resulting
|
||||
file using `load-file'."
|
||||
(flet ((age (file)
|
||||
(time-to-seconds
|
||||
(float-time
|
||||
(time-subtract (current-time)
|
||||
(nth 5 (or (file-attributes (file-truename file))
|
||||
(file-attributes file)))))))
|
||||
|
|
Loading…
Reference in New Issue