2.1 Compiling a file

“Compiling” is the term used for processing an input file in LilyPond format to produce output file(s). Output files are generally PDF (for printing or viewing), MIDI (for playing), and PNG (for online use). LilyPond input files are simple text files.

This example shows a simple input file:

\version "2.23.82"
{
  c' e' g' e'
}

The graphical output is:

[image of music]

Note: Notes and lyrics in LilyPond input must always be surrounded by { curly braces }. The braces should also be surrounded by a space unless they are at the beginning or end of a line to avoid ambiguities. They may be omitted in some examples in this manual, but don’t forget them in your own music! For more information about the display of examples in the manual, see How to read the manuals.

In addition, LilyPond input is case sensitive. ‘{ c d e }’ is valid input; ‘{ C D E }’ produces an error message.


LilyPond — Learning Manual v2.23.82 (development-branch).