From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Eric Schulte" Subject: Re: [babel] Painless integration of source blocks with language Date: Thu, 13 Jan 2011 14:23:54 -0700 Message-ID: <87bp3ka458.fsf@gmail.com> References: <87lj2ukfia.fsf@gmail.com> <87k4icegwl.fsf@ucl.ac.uk> <87wrmbwdsm.fsf@gmail.com> <87aaj5tbgl.fsf@ucl.ac.uk> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from [140.186.70.92] (port=33300 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PdUei-0004XN-SN for emacs-orgmode@gnu.org; Thu, 13 Jan 2011 16:24:30 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PdUeg-0002KQ-NN for emacs-orgmode@gnu.org; Thu, 13 Jan 2011 16:24:28 -0500 Received: from mail-pz0-f41.google.com ([209.85.210.41]:47600) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PdUeg-0002K5-Iu for emacs-orgmode@gnu.org; Thu, 13 Jan 2011 16:24:26 -0500 Received: by pzk27 with SMTP id 27so346311pzk.0 for ; Thu, 13 Jan 2011 13:24:25 -0800 (PST) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Seth Burleigh Cc: emacs-orgmode@gnu.org I briefly mentioned the approach you describe below earlier in this thread [1], and while I see the appeal of this approach, I think that the second approach I described in that same message (using offsets instead of comments) is preferable -- although I am of course open to being persuaded otherwise. Best -- Eric Seth Burleigh writes: > I would just like to throw in a quick idea. > The easiest way to support noweb tangling is to get org-babel-tangle to > create nested tags and change detangle to take these into account. > > for example, i have the forex_user source block that is tangled. > > ;; [[file:~/Dropbox/.rep/clj-forex/clj-forex.org::*User][forex_user]] > my code... > ;; [[file:~/Dropbox/.rep/clj-forex/clj-forex.org::*User][embedded_block]] > my embedded code ... > ;; embedded_block ends here > ;; forex_user ends here > > corresponding to a forex_user block of > #+begin_src > my code ... > <> > #+end_src > > This would only work for noweb on separate lines and preferably only when > one block is noweb embedded into one other source block, but i believe that > this is the most common case anyways. This could be enforced in the > detangle/tangle code. > > Then, a separate minor mode could make these file: markers invisible and > create a colored overlay pattern per source block code. Saving the file > would still save the markers, you just wouldnt see them if the minor mode > was on. Footnotes: [1] http://thread.gmane.org/gmane.emacs.orgmode/35863/focus=35971