lilypond-user
[Top][All Lists]
Advanced

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

Wish for short version function


From: Noeck
Subject: Wish for short version function
Date: Fri, 10 Jan 2014 09:54:10 +0100
User-agent: Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.2.0

Hi all,

I have a wish for a scheme function integrated in LilyPond:
A function that returns the short form of the version used: e.g. 2.18
(and not 2.18.0)


I don’t know if that already exists, I couldn’t find it anywhere. The
reason why I want this function is below. It would be very easy to
implement: In scm/lily.scm after the definition of lilypond-version, one
could add:

(define-safe-public (lilypond-short-version) ; or short-lilypond-version
  (string-join
   (map (lambda (x) (if (symbol? x)
                        (symbol->string x)
                        (number->string x)))
        (list-head (ly:version) 2))
   "."))


What for?
For a custom tagline like: Lilypond 2.18

As \version statement I always use the full (2.18.0) version (for
convert-ly reasons). But on the printed score this is too much (imho).
It doesn’t mean anything to singers in a choir. But I still want to
mention LP and for those who know it, it would be nice to see if the
used version was new or old. Many programs have version numbers without
dots and that’s what people are used to: Windows 95, Windows 8, Sibelius
7, Finale 2014 etc. The major version number contains almost no
information, so I need the next one, too.

Why integrated?
Surely I can write this in my own include, but if this already comes
with LP, it is safer to use it in scores for Mutopia etc. as chances are
higher that it can be automatically updated to future versions of LP.

Cheers,
Joram



reply via email to

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