cleaned version of body is now added to kill ring

This commit is contained in:
Eric Schulte 2009-06-14 11:10:09 -07:00
parent 1b39a64fbe
commit d1bcb5e425
2 changed files with 8 additions and 2 deletions

View File

@ -125,7 +125,7 @@ of the source block to the kill ring."
(unless (member lang org-babel-interpreters) (unless (member lang org-babel-interpreters)
(error "Language is not in `org-babel-interpreters': %s" lang)) (error "Language is not in `org-babel-interpreters': %s" lang))
;; copy body to the kill ring ;; copy body to the kill ring
(with-temp-buffer (insert body) (copy-region-as-kill (point-min) (point-max))) (with-temp-buffer (insert (org-babel-trim body)) (copy-region-as-kill (point-min) (point-max)))
;; if called with a prefix argument, then process header arguments ;; if called with a prefix argument, then process header arguments
(if arg (funcall (intern (concat "org-babel-prep-session:" lang)) session params)) (if arg (funcall (intern (concat "org-babel-prep-session:" lang)) session params))
;; just to the session using pop-to-buffer ;; just to the session using pop-to-buffer

View File

@ -677,11 +677,17 @@ For lack of a better place, lets add this to the
#+srcname: task-ruby-pop-to-session #+srcname: task-ruby-pop-to-session
#+begin_src ruby :var num=9 :var another="something else" #+begin_src ruby :var num=9 :var another="something else"
num.times{|n| puts another}
#+end_src
**** TODO python
#+srcname: task-python-pop-to-session
#+begin_src python :var num=9 :var another="something else"
num.times{|n| puts n} num.times{|n| puts n}
#+end_src #+end_src
**** TODO R **** TODO R
**** TODO python
**** TODO shell **** TODO shell
*** TODO function to dump last N lines from inf-proc buffer into the current source block *** TODO function to dump last N lines from inf-proc buffer into the current source block