Next iteration
I found out that using
#(ly:parser-parse-string (ly:parser-clone parser) "\\include \"01.ily\"")
_does_ actually work, but not when the included file contains variable
definitions (e.g. "music = ...").
If it contains only, say, a \header block, everything works as expected.
I'm aware that the scope is crucial on that level, but I still don't
know what I can do to include a file with a music variable definition in it.
Still no ideas?
Best
Urs
Am 07.09.2014 16:56, schrieb Urs Liska:
No ideas anybody?
I'm desparately hoping for a solution while being quite hopeless
finding one on my own ...
Best
Urs
Am 06.09.2014 12:19, schrieb Urs Liska:
Am 06.09.2014 11:43, schrieb Urs Liska:
Am 06.09.2014 00:40, schrieb Urs Liska:
Am 06.09.2014 00:36, schrieb Urs Liska:
Hi all,
I'm looking for a solution to conditionally include a file if it
exists
Oops.
Well, the question is real, but of course I intended to add more to
it ...
The idea is to include a file with a number of music variables and
then include files that contain one music variable each, overriding
one variable from the first included file.
So if no file is included the (empty) variable from the first file
is used, otherwise the individual variable from the single file.
Urs
A first approach may point in a direction, although it doesn't work
at all.
please consider the attached files: collect.ly tries to include 01
through
#(ly:parser-parse-string (ly:parser-clone parser) "\\include
\"01.ily\""))
(an approach that worked successfully in another situation).
But obviously it doesn't understand the content of 01.ily, as I get
01.ily:4:3 <0>: error: unrecognized string, not in text script or
\lyricmode
c d e f g
errors (and subsequently one more for each of the notes).
So how can I include a file containing music variables through Scheme
(in order to generate the filenames to be included programatically)?
TIA
Urs
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user