From 9f6932f32d3d203265bf5f2fab729de293ee1f8a Mon Sep 17 00:00:00 2001 From: Starbeamrainbowlabs Date: Fri, 25 Oct 2019 01:06:33 +0100 Subject: [PATCH] Swap lilypond out for abcm2ps, which is much easier to integrate with. --- peppermint.guiconfig.json | 14 +-- test.ly | 179 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 186 insertions(+), 7 deletions(-) create mode 100644 test.ly diff --git a/peppermint.guiconfig.json b/peppermint.guiconfig.json index 82b59ca..d74a111 100644 --- a/peppermint.guiconfig.json +++ b/peppermint.guiconfig.json @@ -25,7 +25,7 @@ "parser_ext_renderers": { "type": "parserext", "description": "Used by the parsedown parser as an object mapping fenced code block languages to their respective external renderers. Should be in the form language_codeexternal renderer definition. See the default for examples on how to define an external renderer. Warning: On Windows, the enforcement of strict time limits is not possible. Beware of DoS attacks!", "default": { "nomnoml": { "name": "nomnoml", - "description": "The nomnoml UML diagram renderer. Requires the nomnoml npm package to be globally installed.", + "description": "The nomnoml UML diagram renderer. Requires the 'nomnoml' npm package to be globally installed.", "url": "http://nomnoml.com/", "cli": "nomnoml {input_file} {output_file} 0", "cli_mode": "file", @@ -39,12 +39,12 @@ "cli_mode": "pipe", "output_format": "image/svg+xml" }, - "lilypond": { - "name": "LilyPond", - "description": "A music notation typesetter. Requires lilypond to be installed. WARNING: Don't enable lilypond if you allow anonymous edits. While every effort has been made to close loopholes, a DoS attack may still be possible against your server.", - "url": "http://lilypond.org/manuals.html", - "cli": "lilypondzzzzzz --silent -ddelete-intermediate-files -dbackend=eps -dresolution=600 --output {output_file} {input_file}", - "cli_mode": "file", + "abc": { + "name": "ABC Notation", + "description": "A simple music notation typesetter. Much easier to understand than Lilypond. Requires abcm2ps to be installed.", + "url": "https://abcnotation.com/", + "cli": "abcm2ps -g -O - -", + "cli_mode": "pipe", "output_format": "image/svg+xml" }, "latexserver": { diff --git a/test.ly b/test.ly new file mode 100644 index 0000000..17552b1 --- /dev/null +++ b/test.ly @@ -0,0 +1,179 @@ +% From https://superuser.com/q/96970/164168 +% TODO: Figure out how to induce lilypond to execute this *first* +\paper { + indent = 0\mm + line-width = 200\mm + oddHeaderMarkup = "" + evenHeaderMarkup = "" + oddFooterMarkup = "" + evenFooterMarkup = "" +} + + +% Created on Sun Feb 26 14:01:54 PST 2012 +\version "2.14.0" + +\header { + title = "I'll Walk With You" + composer = "Carol Lynn Pearson and Reid N Nibley" + + %tagline = "169" +} +\paper { + oddFooterMarkup = \markup { "Childrens Songbook 140-141" } + +} + +\include "predefined-ukulele-fretboards.ly" + +mynotes = { + + s2. fis4 + d e fis g + e e8 d e2 + b4 cis8 d e4 fis + d d d fis + 4 g2 4 + 2. fis4 + d e fis g + e e8 d e2 + b4 cis8 d e4 fis + d d d fis + 4 g2 4 + 2. d4 + fis e e + g fis fis + e fis g a + 2 cis + d1 ( + d2.) r4 + 4 b cis' + a' a' + a b' + d, d d fis + g2 4 + 1 + fis4 e fis e + e e a e + e d e d + a' b g + 4 e2 fis4 + d1 + 4 g2 4 + 2. d4 + fis e e + g fis fis + e fis g a + 2 + 1 + + +} + +myFretChords = { + \chordmode { + d e:m g a:7 b:m e:7 a d:7 a:m + + } +} +\score{ + << + \new ChordNames { + \myFretChords + } + \new FretBoards { + \set Staff.stringTunings = #ukulele-tuning + \myFretChords + } +>> +} + + +\score { + << + + + + \new ChordNames { + \chordmode { + d1 s e:m + g2 a:7 d1 g2 a:7 d1 + s e:m g2 a:7 d1 + g2 a:7 d1 e:m d + e:m s2 a:7 d1 + s + b2:m e:7 + a1 a2:m d:7 g1 e2:m a:7 d1 + e:7 a d:7 g + a:7 d g2 a:7 + d1 e:m + d1 e:m s2 a:7 d1 + + } + + } + + \new Staff { + + \time 4/4 + \clef treble + %\transpose cis d { + \key d \major + \relative c' { + % Type notes here + \mynotes + } + % } + } + + + + \addlyrics { + %verse 1 + + If you don't walk as most peo -- ple do, +Some peo -- ple walk a -- way from you, +But I won't! I won't! +If you don't talk as most peo -- ple do, +Some peo -- ple talk and laugh at you, +But I won't! I won't! +I'll walk with you. I'll talk with you. +That's how I'll show my love for you. +Je -- sus walked a -- way from none. +He gave his love to ev -- 'ry -- one. +So I will! I will! +Je -- sus blessed all he could see, +Then turned and said, Come, fol -- low me. +And I will! I will! +I will! I will! +I'll walk with you. I'll talk with you. +That's how I'll show my love for you. + + + } + \addlyrics{ + %verse 2 + + + + } + + + \new TabStaff { + \set TabStaff.stringTunings = #ukulele-tuning + %\transpose cis d{ + \relative c'{ + \mynotes + %\myNewNotes + } + % } + } + +>> +%\midi{} + + +} + + +