From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christopher Witte Subject: Re: [ANN] Org-babel integrated into Org-mode Date: Fri, 2 Jul 2010 17:50:59 +0200 Message-ID: References: <87wrtp78rg.fsf@gmail.com> <87r5jr855m.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: Received: from [140.186.70.92] (port=56889 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OUiW8-0008NR-5l for emacs-orgmode@gnu.org; Fri, 02 Jul 2010 11:51:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OUiW6-0002wd-NM for emacs-orgmode@gnu.org; Fri, 02 Jul 2010 11:51:04 -0400 Received: from mail-bw0-f41.google.com ([209.85.214.41]:33678) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OUiW6-0002wV-D1 for emacs-orgmode@gnu.org; Fri, 02 Jul 2010 11:51:02 -0400 Received: by bwz9 with SMTP id 9so2093117bwz.0 for ; Fri, 02 Jul 2010 08:51:00 -0700 (PDT) In-Reply-To: <87r5jr855m.fsf@gmail.com> 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: Org Mode Eric, Thanks, it all appears to be working now. Cheers, Chris. On 28 June 2010 18:59, Eric Schulte wrote: > Hi Christopher, > > Christopher Witte writes: > >> I'm having trouble getting the new version of babel to work with >> haskell and R under Ubuntu 10.04 using emacs-snapshot. =A0It works fine >> for emacs-lisp. =A0I had to change the variable LISPF in the Makefile >> to: >> >> LISPF =A0 =A0 =A0=3D =A0org.el =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0\ >> ..... >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/ob.el =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/ob-table.el =A0 =A0 =A0 =A0 =A0 =A0 = =A0 \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/ob-lob.el =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/ob-ref.el =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/ob-exp.el =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/ob-tangle.el =A0 =A0 =A0 =A0 =A0 =A0 = =A0\ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/ob-comint.el =A0 =A0 =A0 =A0 =A0 =A0 = =A0\ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/ob-keys.el =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0\ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/langs/ob-emacs-lisp.el =A0 =A0\ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/langs/ob-haskell.el =A0 =A0 =A0 \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/langs/ob-latex.el \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/langs/ob-sh.el =A0 =A0\ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/langs/ob-asymptote.el =A0 =A0 \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/langs/ob-R.el =A0 =A0 \ >> =A0 =A0 =A0 =A0 =A0 =A0 =A0 babel/langs/ob-gnuplot.el >> >> otherwise I couldn't compile my .emacs file, which contains the followin= g: >> > > Hmm, I would think it would be possible to require files which are not > byte-compiled. =A0The reason that the language files (aside from > emacs-lisp) are not compiled by default is that they often have exotic > requirements which will not be present on most users systems. > >> >> (require 'org-install) >> >> ;;(require 'org) >> ;;(require 'ob) >> ;;(require 'ob-tangle) >> ;; org-babel set up >> (require 'ob-haskell) >> (require 'ob-latex) >> (require 'ob-sh) >> (require 'ob-asymptote) >> (require 'ob-R) >> (require 'ob-gnuplot) >> >> The following works fine: >> =A0 =A0 =A0 =A0 =A0 #+tblname: example-table >> =A0 =A0 =A0 =A0 =A0 | 1 | >> =A0 =A0 =A0 =A0 =A0 | 2 | >> =A0 =A0 =A0 =A0 =A0 | 3 | >> =A0 =A0 =A0 =A0 =A0 | 4 | >> >> =A0 =A0 =A0 =A0 =A0 #+source: table-length >> =A0 =A0 =A0 =A0 =A0 #+begin_src emacs-lisp =A0:var table=3Dexample-table >> =A0 =A0 =A0 =A0 =A0 (length table) >> =A0 =A0 =A0 =A0 =A0 #+end_src >> >> =A0 =A0 =A0 =A0 =A0 #+results: table-length >> =A0 =A0 =A0 =A0 : 4 >> >> But when I try the haskell equivalent: >> =A0 =A0 =A0 =A0 =A0 #+source: table-length >> =A0 =A0 =A0 =A0 =A0 #+begin_src haskell =A0:var table=3Dexample-table >> =A0 =A0 =A0 =A0 =A0 length table >> =A0 =A0 =A0 =A0 =A0 #+end_src >> >> >> I get: >> executing haskell source code block >> reference 'example-table' not found in this buffer >> org-babel-ref-resolve-reference: reference 'example-table' not found >> in this buffer >> >> If I try: >> =A0 =A0 =A0 =A0 =A0 #+source: table-length >> =A0 =A0 =A0 =A0 =A0 #+begin_src haskell >> =A0 =A0 =A0 =A0 =A0 length [1,2,3] >> =A0 =A0 =A0 =A0 =A0 #+end_src >> >> >> I get: >> executing haskell source code block >> org-babel-execute:haskell: Symbol's function definition is void: session >> > > Thanks for bringing this up, it looks like ob-haskell has fallen victim > to bit-rot. =A0I've done a fairly thorough cleanup of the file (just > pushed up the commit). =A0Please give it a test run and let me know > if/where I missed issues. > >> >> >> I also get a lot of warnings when I compile org-mode, see the attached >> buiild log. >> > > Yes, the language-specific files have not been manicured for clean > byte-compilation. =A0This is certainly something that should happen, but > probably not in the near term. > > Thanks -- Eric > >> >> >> Thanks for your help, >> >> Chris Witte. >> >> On 23 June 2010 23:09, Eric Schulte wrote: >>> Hi, >>> >>> I've just merged the babel branch into the main branch of Org-mode. >>> This merge culminates much integration work by Dan Davison and Tom Dye, >>> as well as myself. >>> >>> Babel is now part of Org-mode. >>> >>> The biggest changes are: >>> >>> 1) Babel now has documentation! =A0It is part of Org-mode's documentati= on >>> >>> =A0 see Chapter 14 _Working With Source Code_ >>> >>> =A0 also, the Babel keybindings are now listed in the refcard, and can = be >>> =A0 viewed from any Org-mode buffer by pressing C-c C-v h >>> >>> 2) Babel will now be loaded by default along with the rest of Org-mode. >>> =A0 This means that *everyone* currently using babel will need to chang= e >>> =A0 their Emacs config and remove the (require 'org-babel-int) and/or >>> =A0 (require 'org-babel) lines. >>> >>> =A0 Support for evaluating emacs-lisp code blocks is loaded by default. >>> =A0 All other languages will need to be required explicitly. =A0To conf= orm >>> =A0 to Emacs filename specifications all language require lines have be= en >>> =A0 shortened from e.g. >>> >>> =A0 (require 'org-babel-sh) >>> >>> =A0 to >>> >>> =A0 (require 'ob-sh) >>> >>> Thanks -- Eric >>> >>> _______________________________________________ >>> 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 >>> >> >> _______________________________________________ >> 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 >