-
Notifications
You must be signed in to change notification settings - Fork 0
/
book_config.toml
157 lines (141 loc) · 7.53 KB
/
book_config.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
[songbook]
# The songbook section contains general information about the songbook.
# They will be passed to the templates as variables.
title = "The Swilling Swede's Songbook" # The title of the songbook.
author = "Sveinn the Swilling Swede" # The author of the songbook.
publish_date = 2023-10-31 # The date the songbook was published.
license = "CC BY-SA 4.0" # The license of the songbook.
license_url = "https://creativecommons.org/licenses/by-sa/4.0/" # The URL of the license.
title_blurb = """A collection of SONGS humbly presented for your amusement preferably around a CAMPFIRE while drinking MEAD, SCOTCH, BEER, OR RUM and surrounded by good COMPANY."""
# Each section has a name, and a list of files to include in that section.
# The files can be either individual songs or directories containing songs.
[sections."Songs"]
files = ["songs/"]
sort = "filename" # Sort the songs by filename.
[sections."Sir Patrik's Favourites"]
files = ["sir_patriks_favourites/"]
sort = "filename"
# The output_formats section contains information about the different formats
# you want to generate for your songbook. Each format has a name, and a type.
# The type can be one of "html", "pdf", or "epub".
[output_formats.bound_pdf]
type = "pdf"
output_dir = "pdfs"
output_file = "SwillingSwedesSongbook-BoundPrint" # The file extension will be added automatically.
songbook_template = "songbook.tex" # Main tex file for the songbook.
songbook_style = "tex/songs.sty" # Style file for the songbook, containing custom commands.
image_dir = "img/" # Directory containing images. This will be copied to the build directory.
template_dir = "tex/" # Directory containing tex templates. All of these will be rendered with Jinja2 into the build directory.
# Additional variables that will be passed to all templates, including the main template.
[output_formats.bound_pdf.render_variables]
documentclass = "book" # The documentclass of the PDF.
papersize = "letterpaper, twoside" # The paper size of the PDF.
margin.top = "2cm" # The margins of the PDF.
margin.bottom = "2cm"
margin.inner = "4cm"
margin.outer = "2cm"
frontcover = "frontcover.tex" # File containing the front cover.
frontcover_image = "img/longship.png"
frontcover_blank_back = true # Whether to include a blank page after the front cover.
titlepage = "titlepage.tex" # File containing the title page.
intro = "intro.tex" # File containing the intro.
backcover = "backcover.tex" # File containing the back cover.
backcover_image = "img/back.jpg"
backcover_num_blank_pages = 2 # Number of blank pages to include before the back cover.
sbd_header = '''
\newcommand{\tuneof}{}
\newsongkey{tune}{\def\tuneof{}}
{\def\tuneof{Tune: #1\par}}
\renewcommand{\extendprelude}{
%{\itshape\normalsize}
\showrefs\showauthors
{\itshape\normalsize\tuneof}
}
'''
[output_formats.display_pdf]
type = "pdf"
output_dir = "pdfs"
output_file = "SwillingSwedesSongbook-Display" # The file extension will be added automatically.
songbook_template = "songbook.tex" # Main tex file for the songbook.
songbook_style = "tex/songs.sty" # Style file for the songbook, containing custom commands.
image_dir = "img/" # Directory containing images. This will be copied to the build directory.
template_dir = "tex/" # Directory containing tex templates. All of these will be rendered with Jinja2 into the build directory.
# Additional variables that will be passed to all templates, including the main template.
[output_formats.display_pdf.render_variables]
documentclass = "book" # The documentclass of the PDF.
papersize = "letterpaper, twoside" # The paper size of the PDF.
margin.top = "2cm" # The margins of the PDF.
margin.bottom = "2cm"
margin.inner = "3cm"
margin.outer = "3cm"
frontcover = "frontcover.tex" # File containing the front cover.
frontcover_image = "img/longship.png"
titlepage = "titlepage.tex" # File containing the title page.
intro = "intro.tex" # File containing the intro.
backcover = "backcover.tex" # File containing the back cover.
backcover_image = "img/back.jpg"
backcover_num_blank_pages = 0 # Number of blank pages to include before the back cover.
sbd_header = '''
\newcommand{\tuneof}{}
\newsongkey{tune}{\def\tuneof{}}
{\def\tuneof{Tune: #1\par}}
\renewcommand{\extendprelude}{
%{\itshape\normalsize}
\showrefs\showauthors
{\itshape\normalsize\tuneof}
}
'''
[output_formats.ereader_pdf]
type = "pdf"
output_dir = "pdfs"
output_file = "SwillingSwedesSongbook-eReader" # The file extension will be added automatically.
songbook_template = "songbook_ereader.tex" # Main tex file for the songbook.
songbook_style = "tex/songs.sty" # Style file for the songbook, containing custom commands.
image_dir = "img/" # Directory containing images. This will be copied to the build directory.
template_dir = "tex/" # Directory containing tex templates. All of these will be rendered with Jinja2 into the build directory.
# Additional variables that will be passed to all templates, including the main template.
[output_formats.ereader_pdf.render_variables]
margin.top = "2cm" # The margins of the PDF.
margin.bottom = "2cm"
margin.inner = "3cm"
margin.outer = "3cm"
frontcover = "frontcover.tex" # File containing the front cover.
frontcover_image = "img/longship.png"
titlepage = "titlepage.tex" # File containing the title page.
intro = "intro.tex" # File containing the intro.
backcover = "backcover.tex" # File containing the back cover.
backcover_image = "img/back.jpg"
sbd_header = '''
\newcommand{\tuneof}{}
\newsongkey{tune}{\def\tuneof{}}
{\def\tuneof{Tune: #1\par}}
\renewcommand{\extendprelude}{
%{\itshape\normalsize}
\showrefs\showauthors
{\itshape\normalsize\tuneof}
}
'''
[output_formats.ereaders]
type = "epub"
output_dir = "songbook_epub"
output_file = "songbook.epub"
songbook_template = "songbook_epub.tex" # Main tex file for the songbook.
songbook_style = "tex/songs.sty" # Style file for the songbook, containing custom commands.
image_dir = "img/" # Directory containing images. This will be copied to the build directory.
template_dir = "tex/" # Directory containing tex templates. All of these will be rendered with Jinja2 into the build directory.
frontcover = "frontcover.tex" # File containing the front cover.
frontcover_image = "img/longship.png"
titlepage = "titlepage.tex" # File containing the title page.
intro = "intro.tex" # File containing the intro.
backcover = "backcover.tex" # File containing the back cover.
backcover_image = "img/back.jpg"
sbd_header = '''
\newcommand{\tuneof}{}
\newsongkey{tune}{\def\tuneof{}}
{\def\tuneof{Tune: #1\par}}
\renewcommand{\extendprelude}{
%{\itshape\normalsize}
\showrefs\showauthors
{\itshape\normalsize\tuneof}
}
'''