forked from sebgoa/cloudstack-books
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
31 lines (23 loc) · 931 Bytes
/
Makefile
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
SOURCE_FILE_NAME_1 = clients.markdown
BOOK_FILE_NAME_1 = clients
SOURCE_FILE_NAME_2 = installation.markdown
BOOK_FILE_NAME_2 = installation
PDF_BUILDER = pandoc
PDF_BUILDER_FLAGS = \
--latex-engine xelatex \
--template ../common/pdf-template.tex \
--listings
EPUB_BUILDER = pandoc
EPUB_BUILDER_FLAGS = \
--epub-cover-image
clients-pdf:
cd en && $(PDF_BUILDER) $(PDF_BUILDER_FLAGS) $(SOURCE_FILE_NAME_1) -o $(BOOK_FILE_NAME_1).pdf
clients-epub: en/title.png en/title.1.txt en/clients.markdown
$(EPUB_BUILDER) $(EPUB_BUILDER_FLAGS) $^ -o ./en/$(BOOK_FILE_NAME_1).epub
installation-pdf: en/title.png en/title.2.txt en/installation.markdown
cd en && $(PDF_BUILDER) $(PDF_BUILDER_FLAGS) $(SOURCE_FILE_NAME_2) -o $(BOOK_FILE_NAME_2).pdf
installation-epub: en/title.png en/title.2.txt en/installation.markdown
$(EPUB_BUILDER) $(EPUB_BUILDER_FLAGS) $^ -o ./en/$(BOOK_FILE_NAME_1).epub
clean:
rm -f */*.pdf
rm -f */*.epub