-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.sh
67 lines (59 loc) · 1.23 KB
/
build.sh
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
#!/bin/bash
#
# Buku Panduan BlankOn Builder
#
# pandoc 1.12.4.2
# Compiled with texmath 0.6.6.1, highlighting-kate 0.5.8.5.
#
THEME='blankon-template-ccbysa.tex'
#THEME='blankon.tex'
VERSION='1.0'
DOC='buku-panduan'
RILIS='rote'
TARGET='output'
BROWSER='firefox'
LOKASI='content'
echo "Menghapus berkas sebelumnya"
rm $DOC-$RILIS.html
rm -rf $TARGET/*
mkdir -p $TARGET/
echo "Membuat berkas text"
# text
pandoc \
-o $TARGET/$DOC-$RILIS.txt $LOKASI/*md
echo "Membuat berkas html"
# HTML
pandoc \
-o $DOC-$RILIS.html $LOKASI/*md
echo "Membuat berkas pdf normal"
# PDF Normal
pandoc \
--template $THEME \
--variable version=$VERSION \
-V documentclass=book \
-V links-as-notes \
--toc -N \
-o $TARGET/$DOC-$RILIS.pdf $LOKASI/*md
echo "Membuat berkas pdf hitam putih"
# PDF Black & White
pandoc \
--template $THEME \
--variable version=$VERSION \
-V documentclass=book \
-V links-as-notes \
-V urlcolor=black \
-V linkcolor=black \
--no-highlight \
--toc -N \
-o $TARGET/$DOC-$RILIS-bw.pdf $LOKASI/*md
echo "Membuat berkas odt"
# Word
pandoc \
--variable version=$VERSION \
-V documentclass=book \
-V links-as-notes \
--toc -N \
-o $TARGET/$DOC-$RILIS.odt $LOKASI/*md
#echo "Membuka berkas html"
#$BROWSER $TARGET/$RILIS/$DOC-$RILIS.html
echo "Selesai"