diff options
author | Eric Schulte <schulte.eric@gmail.com> | 2010-07-28 08:05:30 -0600 |
---|---|---|
committer | Eric Schulte <schulte.eric@gmail.com> | 2010-07-28 08:05:30 -0600 |
commit | dc92eaa08d89e4bc9556f868ae65633196157a8d (patch) | |
tree | 1d2b5045569bac48ffe1c486a0ab681e21258f32 | |
parent | f6ccee2568a60d855bca5d667128e889bbbbf9c5 (diff) | |
download | org-mode-dc92eaa08d89e4bc9556f868ae65633196157a8d.tar.gz |
ob-R: improved prompt-stripping regexp thanks to Charles C. Berry
* lisp/ob-R.el (org-babel-R-evaluate): improved prompt-stripping
regexp
-rw-r--r-- | lisp/ob-R.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/ob-R.el b/lisp/ob-R.el index 603c1c3..eae3669 100644 --- a/lisp/ob-R.el +++ b/lisp/ob-R.el @@ -259,7 +259,8 @@ return the value of the last statement in BODY, as elisp." (delq nil (mapcar (lambda (line) ;; cleanup extra prompts left in output - (if (string-match "^\\([ >]+\\)\\[[0-9]+\\]" line) + (if (string-match + "^\\([ ]*[>+][ ]?\\)+\\([[0-9]+\\|[ ]\\)" line) (substring line (match-end 1)) line)) (org-babel-comint-with-output (session org-babel-R-eoe-output) |