Le samedi 18 février 2023 à 11:55 -0500, Fr. Samuel Springuel a écrit : > I have the following scheme function which I used on versions 2.22 and > earlier which determined the requested output files for a lilypond run: > > #(define target-extensions (cond ((equal? (ly:get-option 'backend) 'svg) > (list "svg")) > ((equal? (ly:get-option 'backend) 'scm) > (list "scm")) > ((equal? (ly:get-option 'backend) 'ps) > (uniq-list (sort-list (ly:output-formats) string<?))) > ((equal? (ly:get-option 'backend) 'eps) (map > (lambda (str) (if (equal? str "ps") "eps" str)) (uniq-list (sort-list > (ly:output-formats) string<?)))) > (else '()))) > > Now, I realize that the list of possible backends has changed (from ps, eps, > null, scm, and svg to ps, cairo, and svg) so I have to make some adjustments > there, but the ps and cairo backends both can produce multiple different > types of files. For the old ps backend, what was requested used to be > available in ly:output-formats, but this function has been removed (commit > bf3af63b seems to be the culprit). I’m having trouble, however, figuring out > where the information has migrated to (I assume it still has to be stored > somewhere). Can anyone provide some additional clarity here?
It's going to be a bit ugly, because the information is now stored internally in C++ and just passed to the output backends (which are internal as well). You would have to parse command-line options like `--pdf` yourself from `#(command-line)`. However, this may be an XY question. What is your use case for determining the requested output files?
signature.asc
Description: This is a digitally signed message part