lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Relative includes, regtests, Scheme and lp parser.


From: Joe Neeman
Subject: Re: Relative includes, regtests, Scheme and lp parser.
Date: Fri, 19 Mar 2010 13:50:30 -0700

On Thu, 2010-03-18 at 16:08 +0100, Valentin Villenave wrote:
> Hi Joe, greetings everybody,
> 
> While working on the regtests I've been wondering if we'd need a
> regtest for the (awesome) behavior that Joe implemented in December
> 2008 (commit 644008f18ec6780a812eee09ca549cf6b929037c requested by
> issue #391).
> 
> I'm not sure *how* this regtest could work (though I suspect it would
> require embedded system commands, to create subdirectories and .ly
> files, then delete them afterwards -- not sure it's worth the
> trouble).

If you don't mind creating subdirectories of input/regression, you can
just set up the directory structure statically.

> While messing with it, I stumbled upon a nice (undocumented AFAICS)
> feature: relative-includes doesn't actually replace, but merely
> overrides the standard behavior: if a file isn't found using the
> relative filepath, then the same path is browsed from the primary .ly
> file. Joe, can you confirm that?

That's right: we just search from the original directory first before
checking the rest of the search path.

> 
> Another question occurred to me: it seems that relative includes only
> work in "pure" LilyPond mode. When embedding the \include command
> inside a Scheme expression, e.g.
> 
>  (ly:parser-parse-string parser "\\include \"mysubdir/foobar.ly\""))
> 
> then it can only take into account the location of the primary entry
> .ly file (in other words, the non-relative path). Is that so?

I'm not sure and I can't check right now. But feel free to file a bug.

Cheers,
Joe






reply via email to

[Prev in Thread] Current Thread [Next in Thread]