This is excellent, Aaron, thanks very much. Learning by example suits me
well, and I'm enjoying getting into Scheme. I use Python + Java all day
long on the job (in fact used Python to generate all of the music parts of
the score I'm working on -- it's originally a Csound piece that was written
usi
On 2020-10-19 7:51 pm, Dave Seidel wrote:
More succinct:
#(begin
(use-modules (guile-user))
(if (not(defined? 'part))
(define partName "")
(define partName (string-append "S" (number->string part)))
)
)
To be even more succinct, observe the following:
Avoid negated predica
On 2020-10-19 7:51 pm, Dave Seidel wrote:
More succinct:
#(begin
(use-modules (guile-user))
(if (not(defined? 'part))
(define partName "")
(define partName (string-append "S" (number->string part)))
)
)
partName =
#(or (false-if-exception (format #f "S~d" (@ (guile-user) pa
More succinct:
#(begin
(use-modules (guile-user))
(if (not(defined? 'part))
(define partName "")
(define partName (string-append "S" (number->string part)))
)
)
though the warning still prints, but that's not a big deal for me.
On Mon, Oct 19, 2020 at 10:23 PM Dave Seidel wrote:
Interesting. I don't understand the '@' syntax -- been trying to look it up
but so far to no avail.
Here's what I ended up with:
#(begin
(use-modules (guile-user))
(if (not(symbol? 'part))
(define part 0)
)
(if (= part 0)
(define partName "")
(define partName (string-append
On 2020-10-19 2:45 pm, Jean Abou Samra wrote:
You can ignore the warning that shows up
(https://gitlab.com/lilypond/lilypond/-/issues/3613).
You can avoid the warning by using the @ syntax:
eval-scope.ly
\version "2.20.0"
#(format #t "\nvalue = ~s"
(false-if-exception (@ (guile-use
Thanks Jean! I need to read more carefully!
On Mon, Oct 19, 2020 at 5:45 PM Jean Abou Samra wrote:
>
> Le 19/10/2020 à 23:14, Dave Seidel a écrit :
>
> Hi all,
>
> I am trying to define a variable on the command line that I can use within
> the .ly file. I've tried both
>
> -e "(define-public pa
Le 19/10/2020 à 23:14, Dave Seidel a écrit :
Hi all,
I am trying to define a variable on the command line that I can use
within the .ly file. I've tried both
-e "(define-public part 1)"
and
-e "(define part 1)"
In the .ly file, I have a Scheme expression
#(if (= part 0)
Hi all,
I am trying to define a variable on the command line that I can use within
the .ly file. I've tried both
-e "(define-public part 1)"
and
-e "(define part 1)"
In the .ly file, I have a Scheme expression
#(if (= part 0)
(define partName "")
(define partName (string-append "S" part)
Don Blaheta <[EMAIL PROTECTED]> writes:
> I've given up trying to compile from CVS, at least from now, so I went
> ahead and downloaded 2.7.33 for OS X. My question is about writing
> Scheme functions; what can go inside the #{ ... #} construct? I thought
> arbitrary Lilypond syntax could go in
I've given up trying to compile from CVS, at least from now, so I went
ahead and downloaded 2.7.33 for OS X. My question is about writing
Scheme functions; what can go inside the #{ ... #} construct? I thought
arbitrary Lilypond syntax could go in there, but
#(def-music-function (parser locati
11 matches
Mail list logo