From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Schulte Subject: Re: Fwd: ob-lilypond: pre- and post-processing of source blocks Date: Mon, 04 Nov 2013 07:00:14 -0700 Message-ID: <87r4aws1w1.fsf@gmail.com> References: <0dabc937-df1c-4b65-971b-f83812526af4@dewdrop-world.net> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:40656) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VdKiA-0005dt-HS for Emacs-orgmode@gnu.org; Mon, 04 Nov 2013 09:01:03 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VdKi6-0002bE-05 for Emacs-orgmode@gnu.org; Mon, 04 Nov 2013 09:00:58 -0500 Received: from mail-pd0-x22a.google.com ([2607:f8b0:400e:c02::22a]:35617) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VdKi5-0002az-O3 for Emacs-orgmode@gnu.org; Mon, 04 Nov 2013 09:00:53 -0500 Received: by mail-pd0-f170.google.com with SMTP id v10so6809878pde.1 for ; Mon, 04 Nov 2013 06:00:52 -0800 (PST) In-Reply-To: (James Harkins's message of "Mon, 4 Nov 2013 20:39:42 +0800") 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: jamshark70@dewdrop-world.net Cc: Emacs-orgmode@gnu.org >> I would like to be able to do the following with ob-lilypond (basic mode): >> >> 1. Wrap the source block in pre- and/or post-strings (specifically to add > "\header { tagline = ##f }" before the music expressions). >> >> 2. Have lilypond compile the block. >> >> 3. Run "convert -trim" on the resulting png. (Haven't figured out how to > use eps output with xelatex.) >> >> Is this at all feasible? If not, where would I stick this stuff into the > orgmode source? >> Look in lisp/ob-lilypond.el. Specifically (1) would be done in `org-babel-expand-body:lilypond', and both (2) and (3) in `org-babel-execute:lilypond'. See http://orgmode.org/worg/org-contribute.html if you want to contribute any enhancements back to Org-mode. Best, -- Eric Schulte https://cs.unm.edu/~eschulte PGP: 0x614CA05D