diff --git a/contrib/babel/lisp/org-babel-ref.el b/contrib/babel/lisp/org-babel-ref.el index 88b09475e..997b66574 100644 --- a/contrib/babel/lisp/org-babel-ref.el +++ b/contrib/babel/lisp/org-babel-ref.el @@ -118,7 +118,7 @@ return nil." (setq split-ref (match-string 2 ref)) (find-file split-file) (setq ref split-ref)) (goto-char (point-min)) - (if (let ((result_regexp (concat "^#\\+\\(TBL\\|RES\\)NAME:[ \t]*" + (if (let ((result_regexp (concat "^#\\+\\(TBLNAME\\|RESNAME\\|RESULT\\):[ \t]*" (regexp-quote ref) "[ \t]*$")) (regexp (concat "^#\\+SRCNAME:[ \t]*" (regexp-quote ref) "\\(\(.*\)\\)?" "[ \t]*$"))) diff --git a/contrib/babel/lisp/org-babel.el b/contrib/babel/lisp/org-babel.el index ae02cb357..4bfda474e 100644 --- a/contrib/babel/lisp/org-babel.el +++ b/contrib/babel/lisp/org-babel.el @@ -94,7 +94,7 @@ then run `org-babel-pop-to-session'." "Regexp used to test when on an inline org-babel src-block") (defvar org-babel-result-regexp - "#\\+resname\\(\\[\\([[:alnum:]]+\\)\\]\\)?\\:" + "#\\+res\\(ults\\|name\\)\\(\\[\\([[:alnum:]]+\\)\\]\\)?\\:" "Regular expressions used to match result lines. If the results are associated with a hash key then the hash will be saved in the second match data.") @@ -553,7 +553,7 @@ following the source block." ;; or (with optional insert) back up and make one ourselves (when insert (goto-char end) (forward-char 1) - (insert (concat "#+resname" (if hash (concat "["hash"]")) + (insert (concat "#+results" (if hash (concat "["hash"]")) ":"(if name (concat " " name)) "\n")) (move-beginning-of-line 0) (if hash (org-babel-hide-hash)) t)))