Skip to content

Instantly share code, notes, and snippets.

@Dapid
Last active December 18, 2019 09:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Dapid/9f44203c46101373963fb3f922c5daae to your computer and use it in GitHub Desktop.
Save Dapid/9f44203c46101373963fb3f922c5daae to your computer and use it in GitHub Desktop.
Latex-lily example
\version "2.19.83"
\language "espanol"
\header {
title = "Amazing Grace"
composer = "Trad. Scottish"
%tagline = ""
}
trumpet = \relative do' {
\key fa \major
\time 3/4
\partial 4 do4 | fa2 la8( fa) | la2 sol4 | fa2 re4 | do2 do4 | fa2 la8( fa) |
la2 sol 4 | do2. ~ | do 4 r la | do2 la8( fa) | la2 sol 4 |
fa2 re4 | do2 4| fa2 la8( fa) | la2 sol4 | fa2.~ | fa4 r \bar "|."
}
melodica = \new Staff \with {\accidentalStyle Score.teaching
} { \transpose do' sib \trumpet}
\score {
<<
\trumpet
\melodica
>>
\midi{\tempo 4=60}
\layout {}
}
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
\documentclass [10pt, a4paper]{article}
\usepackage{fontspec}
\usepackage{lyluatex}
\setmainfont{tex-gyre-pagella}
\title{Example}
\author{David Menéndez Hurtado}
\begin{document}
\maketitle
This is how it all begins: \lilypond{\relative c' {c4 | f2 a8( f) | a2 g4}} and I explain more things.
And now we are ready for a more complete example, with transposition and everything:
\vspace{1em}
\lilypondfile{amazing_grace.ly}
\end{document}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment