diff options
author | Eric Schulte <eric.schulte@gmx.com> | 2012-01-20 12:00:31 -0700 |
---|---|---|
committer | Eric Schulte <eric.schulte@gmx.com> | 2012-01-20 12:00:31 -0700 |
commit | 10f26fb805841e0dfa2404da0e7fb5b011f5b14b (patch) | |
tree | 11cff7ee779af69cf601e4f7a529619a4f1dc974 | |
parent | 5852cf7fbf4dfd6d8465b4752b7566c3f2be475e (diff) | |
parent | 4f5b6317b54c25adad4a6865bdcb7436d05fba75 (diff) | |
download | org-mode-10f26fb805841e0dfa2404da0e7fb5b011f5b14b.tar.gz |
Merge branch 'origin-maint'
-rw-r--r-- | lisp/ob-exp.el | 9 | ||||
-rw-r--r-- | lisp/ob.el | 6 | ||||
-rw-r--r-- | lisp/org-src.el | 3 | ||||
-rw-r--r-- | testing/examples/ob-screen-test.org | 5 |
4 files changed, 17 insertions, 6 deletions
diff --git a/lisp/ob-exp.el b/lisp/ob-exp.el index c0d95d7..a3f0ae3 100644 --- a/lisp/ob-exp.el +++ b/lisp/ob-exp.el @@ -164,7 +164,11 @@ options are taken from `org-babel-default-header-args'." (interactive) (save-excursion (goto-char start) - (while (and (< (point) end) + (unless (markerp end) + (let ((m (make-marker))) + (set-marker m end (current-buffer)) + (setq end m))) + (while (and (< (point) (marker-position end)) (re-search-forward org-babel-lob-one-liner-regexp end t)) (unless (org-babel-in-example-or-verbatim) (let* ((lob-info (org-babel-lob-get-info)) @@ -186,9 +190,6 @@ options are taken from `org-babel-default-header-args'." (butlast lob-info) " "))))) "" nil (car (last lob-info))) 'lob))))) - (setq end (+ end (- (length rep) - (- (length (match-string 0)) - (length (or (match-string 11) "")))))) (if inlinep (save-excursion (goto-char inline-start) @@ -477,7 +477,10 @@ the header arguments specified at the front of the source code block." (interactive) (let ((info (or info (org-babel-get-src-block-info)))) - (when (org-babel-confirm-evaluate info) + (when (org-babel-confirm-evaluate + (let ((i info)) + (setf (nth 2 i) (org-babel-merge-params (nth 2 info) params)) + i)) (let* ((lang (nth 0 info)) (params (if params (org-babel-process-params @@ -905,6 +908,7 @@ buffer." (goto-char (point-min)) (while (re-search-forward ,rx nil t) (goto-char (match-beginning 1)) + (when (looking-at org-babel-inline-src-block-regexp)(forward-char 1)) (save-match-data ,@body) (goto-char (match-end 0)))) (unless visited-p (kill-buffer to-be-removed)) diff --git a/lisp/org-src.el b/lisp/org-src.el index f605ed9..8cdf81e 100644 --- a/lisp/org-src.el +++ b/lisp/org-src.el @@ -153,7 +153,8 @@ but which mess up the display of a snippet in Org exported files.") (defcustom org-src-lang-modes '(("ocaml" . tuareg) ("elisp" . emacs-lisp) ("ditaa" . artist) ("asymptote" . asy) ("dot" . fundamental) ("sqlite" . sql) - ("calc" . fundamental) ("C" . c) ("cpp" . c++)) + ("calc" . fundamental) ("C" . c) ("cpp" . c++) + ("screen" . shell-script)) "Alist mapping languages to their major mode. The key is the language name, the value is the string that should be inserted as the name of the major mode. For many languages this is diff --git a/testing/examples/ob-screen-test.org b/testing/examples/ob-screen-test.org new file mode 100644 index 0000000..19ce147 --- /dev/null +++ b/testing/examples/ob-screen-test.org @@ -0,0 +1,5 @@ +#+Title: a collection of examples for ob-screen tests +#+begin_src screen :session create-tmpdir + mkdir -p $TMPDIR + cd $TMPDIR +#+end_src |