Skip to content

Instantly share code, notes, and snippets.

@msikma
Created February 25, 2016 15:33
Show Gist options
  • Save msikma/f06c38c3e5d2b5871191 to your computer and use it in GitHub Desktop.
Save msikma/f06c38c3e5d2b5871191 to your computer and use it in GitHub Desktop.
include-header =
#(define-void-function (parser location)()
(define lang "")
(define ext ".ily")
(if (defined? 'HEADERS-LANG)
(set! lang (string-append "-" HEADERS-LANG)))
(if (defined? 'HEADERS-EXT)
(set! ext (string-append "." HEADERS-EXT)))
(ly:parser-include-string parser (format "\\include \"~A~A~A\"\n" "header" lang ext)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment