emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] Literate Programming - Continue a Source Block?


From: Neeum Zawan
Subject: Re: [O] Literate Programming - Continue a Source Block?
Date: Tue, 14 Jun 2011 22:17:09 -0700

Eric Schulte <address@hidden> writes:

> Could you try the attached example file?  I first evaluated the
> following elisp code to set the combination variable's value to append.

Your example works if there are no noweb references. 

See the  modified one where I have noweb references. Note that when
expanding the reference, it inserts only the first block it finds. 



 
#+begin_src emacs-lisp :tangle yes :noweb yes
<<foo>>

Random text

<<bar>>
#+end_src



* continued code blocks
   :PROPERTIES:
   :tangle:   yes
   :comments: yes
   :END:
#+srcname: foo
#+begin_src emacs-lisp
  (message "foo:%S" 1)
#+end_src

#+begin_src emacs-lisp
  (message "un-named")
#+end_src

#+srcname: bar
#+begin_src emacs-lisp
  (message "bar:%S" 1)
#+end_src

#+srcname: foo
#+begin_src emacs-lisp
  (message "foo:%S" 2)
#+end_src

#+srcname: bar
#+begin_src emacs-lisp
  (message "bar:%S" 2)
#+end_src

#+begin_src emacs-lisp :tangle no :results silent
  (with-temp-buffer
    (insert-file-contents "scraps.el")
    (eval-buffer))
#+end_src

reply via email to

[Prev in Thread] Current Thread [Next in Thread]