emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: James Harkins <jamshark70@gmail.com>
To: Emacs-orgmode@gnu.org
Cc: Eric Schulte <schulte.eric@gmail.com>
Subject: Re: Fwd: ob-lilypond: pre- and post-processing of source blocks
Date: Tue, 05 Nov 2013 13:35:53 +0800	[thread overview]
Message-ID: <4ac0f0a7-7947-4d64-837e-53898ee47f32@dewdrop-world.net> (raw)
In-Reply-To: <CAFniQ7XHBbty1w8XS7p=RE=fOUD-tjrwGd7Asv0n00PuEGQGrw@mail.gmail.com>

On Tuesday, November 5, 2013 12:24:44 PM HKT, James Harkins wrote:
> On Nov 4, 2013 10:08 PM, "Eric Schulte" <schulte.eric@gmail.com> wrote:
>> 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'.
>
> Thanks. I'm not much of a LISPer so I have no idea when I might get 
around
> to that.
>
> In the meantime, I was just advised that lilypond has a command-line 
switch
> "-dpreview" that should eliminate the need to run "convert -trim." I'll 
try
> that first.

I have managed to get this working, by adding this to .emacs 
(unfortunately, this is not exposed as a defcustom).

(setq ly-nix-ly-path "/usr/bin/lilypond -dpreview")

Incidentally, it would be very useful if babel offered a header argument 
for commandline switches. If there is one, it was not obvious at [1] which 
one it should be.

Then, this actually compiles and displays well enough:

#+name: pitches
#+begin_src lilypond -i :exports both :file pitches.png :prologue 
\header{tagline=##f}
\include "english.ly"
{ c' e' g' fs' a' c'' ef'' d' }
#+end_src

Next up: I would like ":prologue \header{tagline=##f}" to be buffer wide. I 
tried this:

#+PROPERTY: header-args:lilypond :prologue \header{tagline=##f}

.. but it didn't work at first.

[5 minutes]

OK, I had to refresh the buffer setup. That wasn't obvious in the 
documentation.

So it all seems to be working now.

hjh

[1] 
http://orgmode.org/manual/Specific-header-arguments.html#Specific-header-arguments

  reply	other threads:[~2013-11-05  5:36 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <0dabc937-df1c-4b65-971b-f83812526af4@dewdrop-world.net>
2013-11-04 12:39 ` Fwd: ob-lilypond: pre- and post-processing of source blocks James Harkins
2013-11-04 14:00   ` Eric Schulte
2013-11-05  4:24     ` James Harkins
2013-11-05  5:35       ` James Harkins [this message]
2013-11-05  6:17         ` Thomas S. Dye

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4ac0f0a7-7947-4d64-837e-53898ee47f32@dewdrop-world.net \
    --to=jamshark70@gmail.com \
    --cc=Emacs-orgmode@gnu.org \
    --cc=schulte.eric@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).