summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Schulte <schulte.eric@gmail.com>2010-06-07 12:58:38 -0700
committerEric Schulte <schulte.eric@gmail.com>2010-06-07 12:58:38 -0700
commit9c02bf49464beed630aa7b0eda8b5ab90e772fa5 (patch)
tree6a36ca81c46bd419527c3db2ee487d1ffea2cae2
parent8318845f6d6ce6a73f0fca02e064e1b664234deb (diff)
downloadorg-mode-9c02bf49464beed630aa7b0eda8b5ab90e772fa5.tar.gz
babel: more robust newline regexp in `org-babel-comint-with-output'
* contrib/babel/lisp/org-babel-comint.el (org-babel-comint-with-output): Placing a more general regexp substitution for matching newlines returned by comint. This new option should definitely cover all cases.
-rw-r--r--contrib/babel/lisp/org-babel-comint.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/contrib/babel/lisp/org-babel-comint.el b/contrib/babel/lisp/org-babel-comint.el
index 5d19eb6..0189c9a 100644
--- a/contrib/babel/lisp/org-babel-comint.el
+++ b/contrib/babel/lisp/org-babel-comint.el
@@ -97,7 +97,8 @@ during execution of body."
(if (and ,remove-echo
(string-match
(replace-regexp-in-string
- "\n" "\r\n" (regexp-quote ,full-body)) string-buffer))
+ "\n" "[\r\n]+" (regexp-quote ,full-body))
+ string-buffer))
(setq raw (substring string-buffer (match-end 0))))
(split-string string-buffer comint-prompt-regexp))))