From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nick Dokos Subject: Re: Illiterate programming question Date: Thu, 31 Mar 2011 16:13:30 -0400 Message-ID: <4998.1301602410@alphaville.usa.hp.com> References: <4D93935B.1020402@sift.info> <8766.1301520804@alphaville.usa.hp.com> <4D93A425.9070604@sift.info> <87mxkcrzk7.fsf@gmail.com> Reply-To: nicholas.dokos@hp.com Return-path: Received: from [140.186.70.92] (port=54059 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q5OFK-00077w-Pp for emacs-orgmode@gnu.org; Thu, 31 Mar 2011 16:13:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q5OFJ-0006U3-Mk for emacs-orgmode@gnu.org; Thu, 31 Mar 2011 16:13:34 -0400 Received: from g1t0026.austin.hp.com ([15.216.28.33]:2036) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q5OFJ-0006Tv-G3 for emacs-orgmode@gnu.org; Thu, 31 Mar 2011 16:13:33 -0400 In-Reply-To: Message from "Sean O'Halpin" of "Thu, 31 Mar 2011 21:09:18 BST." 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: Sean O'Halpin Cc: nicholas.dokos@hp.com, Org Mode , rpgoldman@sift.info Sean O'Halpin wrote: > On Wed, Mar 30, 2011 at 11:52 PM, Eric Schulte wrote: > > Babel does have a way to bring changes back from pure source code into > > code blocks in an Org-mode document. While it isn't perfect (especially > > if you make extensive use of noweb references or variables) there are > > mechanisms to maintain such a /sync/. To try this out, tangle out code > > with the ":comments yes" header argument, then change an element of the > > tangled source code, and use the `org-babel-detangle' function to bring > > the changes back into the Org-mode document. > > > > Improving the detangling (or "illiterate") features is an area ripe for > > future Babel development. > > > > Cheers -- Eric > > > > > Hi, > > Could anyone please give a working example of this? I tried tangling > the following: > > * A tangle example > > #+source: body > #+begin_src ruby :comments yes :noweb yes > puts "hello" > #+end_src > > #+source: method > #+begin_src ruby :comments yes :noweb yes > def hello > <> > end > #+end_src > > #+source: main > #+begin_src ruby :comments yes :tangle detangle.rb :noweb yes > <> > hello > #+end_src > > and got the output: > > # [[][main]] > > def hello > puts "hello" > end > hello > > # main ends here > > which doesn't look right to me. > What should it look like? Nick