Em seg., 18 de mai. de 2020 às 12:23, David Nalesnik <
[email protected]> escreveu:

> Is it possible to use the <lilypondfile> command in lilypond-book and
> not create a link to the LY file
> in an HTML document?  I'm hoping there is some automation available
> with lilypond-book.
>
> Thanks,
> David
>

I was able to do that tinkering with the file book_html.py, normally found
in your installation directory at
lilypond/[current-version]/scripts/python/book_html.py

You can make lilypond-book output just the image file by removing some
lines. Here is the diff:

68d67
<  </a>
71,72c70
<     BEFORE: r'''<p>
<  <a href="%(base)s%(ext)s">''',
---
>     BEFORE: r'''<p>''',

As you can see, I just removed the parts of the file that create the <a>
tag. Unfortunately I was only able to do that on the actual lilypond
install directory. I tried to make a copy of book_html.py to my local
directory, modify it there, and invoke it both with the
--load-custom-package and --include flags that are mentioned in the man
page, but it didn't work. So, if you are going to change the file in your
ilypond directory _please_ make a backup first.

Cheers!
Caio

Reply via email to