made section templates more flexible

This commit is contained in:
leopoldfajtak
2024-12-05 10:35:07 +01:00
parent 12dc7edf0e
commit 6938f650fd
13 changed files with 62 additions and 124 deletions
+26 -7
View File
@@ -1,6 +1,9 @@
[% PROCESS purpose_processing.tt;
IF variables;
PROCESS "$variables";
IF assignments;
PROCESS "$assignments";
END;
IF overrides != '';
"\[% $overrides %\]" | evaltt;
END;
-%]
\song{[% purpose_print ? purpose_print : purpose %]}{[% song_title -%]}{
@@ -14,10 +17,12 @@
GET "\\gregorioscore{${directory}/${scores.gregorian}}\n";
END;
ELSE;
GET '\lilypondfile{';
IF parts;
IF parts == 'band';
IF scores.leadsheet;
GET '\lilypondfile{';
IF parts == 'band' || parts == 'full';
IF scores.full;
GET "${directory}/${scores.full}";
ELSIF scores.leadsheet;
GET "${directory}/${scores.leadsheet}";
ELSE;
GET "${directory}/${scores.SATB}";
@@ -28,11 +33,25 @@
ELSE;
GET "${directory}/${scores.leadsheet}";
END;
ELSE;
IF scores.${parts};
GET "${directory}/${scores.$parts}";
ELSE;
IF scores.full;
GET "${directory}/${scores.full}";
ELSIF scores.leadsheet;
GET "${directory}/${scores.leadsheet}";
ELSE;
GET "${directory}/${scores.SATB}";
END;
END;
END;
GET "}\n";
ELSE;
GET "${directory}/${scores.congregation}";
IF scores.congregation;
GET "\\lilypondfile{${directory}/${scores.congregation}}\n";
END;
END;
GET "}\n";
END;
ELSIF lyrics;
GET lyrics;