lilypond-user
[Top][All Lists]
Advanced

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

Re: Output PDF to stdout


From: Valentin Petzel
Subject: Re: Output PDF to stdout
Date: Sun, 21 Jan 2024 16:55:28 +0100

Hello Vlad,

You will not avoid intermediate files in any case, as Lilypond with gs output 
will generate ps code, which is then turned into a pdf. If you want to pipe 
PDFs for convenience you might create a wrapper say plilypond in the search 
path doing something like this:

#!/bin/bash

t=$(mktemp) 1>&2
lilypond -o "$t" ${@} 1>&2
cat "$t".pdf
rm "$t".pdf 1>&2

Cheers,
Valentin

Am Donnerstag, 4. Jänner 2024, 23:34:28 CET schrieb Volodymyr Prokopyuk:
> Hi,
> 
> I know that lilypond can receive a source.ly file from the stdin by
> using lilypond
> -. Is it possible for lilypond to output PDF to the stdout?
> 
> My motivation behind using lilypond in a pipeline is to speed up PDF
> generation by avoiding storing intermediary files on disk. The pipeline I'd
> like to implement is
> cat source.ly | lintLy | lilypond - | optimizePDF > score.pdf
> Currently lilypond engraves PDF on disk, so a PDF optimizer has to read,
> optimize, and substitute PDF on disk.
> 
> Thank you,
> Vlad

Attachment: signature.asc
Description: This is a digitally signed message part.


reply via email to

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