From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bastien Subject: Re: [PATCH] Add ob-J.el Date: Fri, 20 Dec 2013 17:13:30 +0100 Message-ID: <87ioujxzyt.fsf@bzg.ath.cx> References: Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:59361) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vu2ho-0005on-NQ for emacs-orgmode@gnu.org; Fri, 20 Dec 2013 11:13:46 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vu2hi-0001Pi-SM for emacs-orgmode@gnu.org; Fri, 20 Dec 2013 11:13:40 -0500 Received: from mail-wg0-x232.google.com ([2a00:1450:400c:c00::232]:33749) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vu2hi-0001PZ-LE for emacs-orgmode@gnu.org; Fri, 20 Dec 2013 11:13:34 -0500 Received: by mail-wg0-f50.google.com with SMTP id a1so2669178wgh.29 for ; Fri, 20 Dec 2013 08:13:33 -0800 (PST) In-Reply-To: (Oleh's message of "Fri, 20 Dec 2013 14:51:30 +0100") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Oleh Cc: org mode Hi Oleh, Oleh writes: > Here's a patch to add babel support for J. Thanks. Are you a FSF-signed contributor? We cannot include this in Org's core without your copyright assignment, let me know. > I couldn't figure out how to make ob-J.elc a target for make, > maybe someone can fix this. No need to create a specific target. Some comments on the code below: > From 0139af8534dc33911ed1a24a9702a156ae46c99d Mon Sep 17 00:00:00 2001 > From: Oleh Krehel > Date: Fri, 20 Dec 2013 14:43:59 +0100 > Subject: [PATCH] Add org-babel support for J. > > --- > lisp/ob-J.el | 134 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ > 1 file changed, 134 insertions(+) > create mode 100644 lisp/ob-J.el > > diff --git a/lisp/ob-J.el b/lisp/ob-J.el > new file mode 100644 > index 0000000..50c1a5a > --- /dev/null > +++ b/lisp/ob-J.el > @@ -0,0 +1,134 @@ > +;;; ob-J.el --- org-babel functions for J evaluation > + > +;; Copyright (C) 2011-2013 Free Software Foundation, Inc. > + > +;; Author: Oleh Krehel > +;; Keywords: literate programming, reproducible research > +;; Homepage: http://orgmode.org > + > +;; This file is part of GNU Emacs. That's for Org's core (the lisp/ directory) but we can add ob-J.el in contrib/lisp/ without the copyright assignment. > + (mapconcat #'identity (split-string body "\n") "\necho''\n")) ^ (mapconcat 'identity ...) is fine. > +(defun org-babel-J-strip-whitespace (str) > +(defun obj-strip-leading-ws (s) Maybe you can use org-trim here. > +;;; ob-J.el ends here Thanks for this contribution! -- Bastien