From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pierre de Buyl Subject: Re: Is it possible to do literate programming without org-babel? Date: Fri, 3 Dec 2010 09:42:13 -0500 Message-ID: References: <4CF8EC16.40500@gmail.com> <87bp53q6fm.fsf@ucl.ac.uk> Mime-Version: 1.0 (Apple Message framework v753.1) Content-Type: text/plain; charset=ISO-8859-1; delsp=yes; format=flowed Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=53001 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1POWq8-00031R-EE for emacs-orgmode@gnu.org; Fri, 03 Dec 2010 09:42:27 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1POWq7-0004Do-9n for emacs-orgmode@gnu.org; Fri, 03 Dec 2010 09:42:24 -0500 Received: from mxin.ulb.ac.be ([164.15.128.112]:10656) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1POWq7-0004CW-4k for emacs-orgmode@gnu.org; Fri, 03 Dec 2010 09:42:23 -0500 In-Reply-To: <87bp53q6fm.fsf@ucl.ac.uk> 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: Eric S Fraga Cc: emacs-orgmode@gnu.org, "I.S." Hello, I have taken a reverse approach, even with no collaboration. I write the source code in pure $LANGUAGE (fortran 90 for now) and =20 add comments in org-mode syntax with a special header: in prog.f90 !!subroutine compute ! This subroutine performs a task subroutine compute(myarg) integer, intent(in) :: myarg write(*,*) myarg end subroutine compute get translated by a script to ** subroutine compute This subroutine performs a task #begin_src f90 subroutine compute(myarg) integer, intent(in) :: myarg write(*,*) myarg end subroutine compute #end_src which can be exported with the language font locking of emacs in html =20= via orgmode. It gives me a typeset documentation from my source code =20 directly. I think that a feature similar to C-' in org-mode would be wonderful: =20= I could edit my "pure" f90 program and edit my comment blocks in org-=20 mode. Regards, Pierre Le 3 d=E9c. 10 =E0 09:25, Eric S Fraga a =E9crit : > "I.S." writes: > >> Dear Experts, >> >> I think org-babel is great and use it when I can. But on larger >> projects where some people are not emacs users, it may not be =20 >> feasible >> for the master file to be an org-mode file. >> >> Do you have any suggestions on using literate programming techniques >> when the source code must be in a .py file? >> >> One thing I have tried is switching to org-mode when I want to write >> comments, create links, etc. and do that in org-mode and then switch >> back to python mode. This actually works reasonably well but it's >> annoying to switch modess. >> >> Any better ideas? > > This probably is not going to help you but I have the same problem. > > What I do, *when* the project is one in which I am the main lead, =20 > is to > keep using org mode, without switching modes, but when I need to share > something with my collaborator, I *tangle* all the code and send him > both the code and the org document. This means that he can run the > code. However, the code has no comments in it... > > Of course, incorporating any changes my collaborator makes back =20 > into the > org document is annoying but manageable. > --=20 > : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 23.2.1 > : using Org-mode version 7.3 (release_7.3.169.g0d0e) > > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode