diff --git a/.travis.yml b/.travis.yml index c9e5e78..c72ea48 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,7 +5,11 @@ addons: - poppler-utils install: tlmgr install mdframed mweights needspace sourcecodepro sourcesanspro collection-fontsextra pdfjam script: | - pandoc --verbose pandoc-metadata.yaml README.md [0-9]*.md -o hack-the-hackerspace.pdf --template eisvogel.tex --toc --listings --metadata date="`date +%D`" --include-before-body=include-cover.tex --include-after-body=include-back.tex + # Generate epub + pandoc --verbose pandoc-metadata.yaml README.md [0-9]*.md -o hack-the-hackerspace.epub --metadata date="`date +%D`" --toc-depth=2 --epub-embed-font='epub-fonts/*.ttf' --css=epub.css + # Generate PDF + pandoc --verbose pandoc-metadata.yaml README.md [0-9]*.md -o hack-the-hackerspace.pdf --metadata date="`date +%D`" --template eisvogel.tex --include-before-body=include-cover.tex --include-after-body=include-back.tex + # Generate booklet numpages=$(pdfinfo hack-the-hackerspace.pdf | awk '/^Pages/ { print $2}') pdfbook hack-the-hackerspace.pdf 2-$(($numpages-2)) -o hack-the-hackerspace-booklet-body.pdf deploy: @@ -13,6 +17,7 @@ deploy: api_key: secure: cIRIKuDWejK79Kojh2URkQBmQcKDJtH/MmrzgCySQ7ArjbZ6/cPkS014QbNmUft4GiRGZzIiulfkkvLtdT4UVGVXEw7gTK/V5b6bEci6fst4rDPL/hCDeXcLutOxcOwb7vei38V5XhE+1D2UcFQFNJFkeo60WKWR9ybIQ7pAemo= file: + - hack-the-hackerspace.epub - hack-the-hackerspace.pdf - hack-the-hackerspace-booklet-cover.pdf - hack-the-hackerspace-booklet-body.pdf @@ -20,4 +25,4 @@ deploy: on: repo: "0x20/HTH" if: - tag IS blank \ No newline at end of file + tag IS blank diff --git a/epub-fonts/OpenSans-Bold.ttf b/epub-fonts/OpenSans-Bold.ttf new file mode 100755 index 0000000..fd79d43 Binary files /dev/null and b/epub-fonts/OpenSans-Bold.ttf differ diff --git a/epub-fonts/OpenSans-BoldItalic.ttf b/epub-fonts/OpenSans-BoldItalic.ttf new file mode 100755 index 0000000..9bc8009 Binary files /dev/null and b/epub-fonts/OpenSans-BoldItalic.ttf differ diff --git a/epub-fonts/OpenSans-ExtraBold.ttf b/epub-fonts/OpenSans-ExtraBold.ttf new file mode 100755 index 0000000..21f6f84 Binary files /dev/null and b/epub-fonts/OpenSans-ExtraBold.ttf differ diff --git a/epub-fonts/OpenSans-ExtraBoldItalic.ttf b/epub-fonts/OpenSans-ExtraBoldItalic.ttf new file mode 100755 index 0000000..31cb688 Binary files /dev/null and b/epub-fonts/OpenSans-ExtraBoldItalic.ttf differ diff --git a/epub-fonts/OpenSans-Italic.ttf b/epub-fonts/OpenSans-Italic.ttf new file mode 100755 index 0000000..c90da48 Binary files /dev/null and b/epub-fonts/OpenSans-Italic.ttf differ diff --git a/epub-fonts/OpenSans-Light.ttf b/epub-fonts/OpenSans-Light.ttf new file mode 100755 index 0000000..0d38189 Binary files /dev/null and b/epub-fonts/OpenSans-Light.ttf differ diff --git a/epub-fonts/OpenSans-LightItalic.ttf b/epub-fonts/OpenSans-LightItalic.ttf new file mode 100755 index 0000000..68299c4 Binary files /dev/null and b/epub-fonts/OpenSans-LightItalic.ttf differ diff --git a/epub-fonts/OpenSans-Regular.ttf b/epub-fonts/OpenSans-Regular.ttf new file mode 100755 index 0000000..db43334 Binary files /dev/null and b/epub-fonts/OpenSans-Regular.ttf differ diff --git a/epub-fonts/OpenSans-Semibold.ttf b/epub-fonts/OpenSans-Semibold.ttf new file mode 100755 index 0000000..1a7679e Binary files /dev/null and b/epub-fonts/OpenSans-Semibold.ttf differ diff --git a/epub-fonts/OpenSans-SemiboldItalic.ttf b/epub-fonts/OpenSans-SemiboldItalic.ttf new file mode 100755 index 0000000..59b6d16 Binary files /dev/null and b/epub-fonts/OpenSans-SemiboldItalic.ttf differ diff --git a/epub-fonts/Oswald-Bold.ttf b/epub-fonts/Oswald-Bold.ttf new file mode 100755 index 0000000..a77a3d0 Binary files /dev/null and b/epub-fonts/Oswald-Bold.ttf differ diff --git a/epub-fonts/Oswald-Light.ttf b/epub-fonts/Oswald-Light.ttf new file mode 100755 index 0000000..3ef58b9 Binary files /dev/null and b/epub-fonts/Oswald-Light.ttf differ diff --git a/epub-fonts/Oswald-Regular.ttf b/epub-fonts/Oswald-Regular.ttf new file mode 100755 index 0000000..0798e24 Binary files /dev/null and b/epub-fonts/Oswald-Regular.ttf differ diff --git a/epub.css b/epub.css new file mode 100644 index 0000000..1deb7b0 --- /dev/null +++ b/epub.css @@ -0,0 +1,64 @@ +@font-face { + font-family: OpenSans; + font-style: normal; + font-weight: normal; + src:url("OpenSans-Regular.ttf"); +} + +@font-face { + font-family: OpenSans; + font-style: normal; + font-weight: bold; + src:url("OpenSans-Bold.ttf"); +} + +@font-face { + font-family: OpenSans; + font-style: normal; + font-weight: lighter; + src:url("OpenSans-Light.ttf"); +} + +@font-face { + font-family: Oswald; + font-style: normal; + font-weight: normal; + src:url("Oswald-Regular.ttf"); +} + +@font-face { + font-family: Oswald; + font-style: normal; + font-weight: bold; + src:url("Oswald-Bold.ttf"); +} + +@font-face { + font-family: Oswald; + font-style: normal; + font-weight: lighter; + src:url("Oswald-Light.ttf"); +} + +body { + margin: 1%; + text-align: justify; + font-size: small; + font-family: OpenSans; + line-height: 1.75; +} +code { font-family: monospace; } +h1 { text-align: left; color: #333; } +h2 { text-align: left; color: #555; } +h3 { text-align: left; } +h4 { text-align: left; } +h5 { text-align: left; } +h6 { text-align: left; } +h1, h2, h3, h4, h5, h6 { + font-family: Oswald; +} +h1.title { } +h2.author { } +h3.date { } +ol.toc { padding: 0; margin-left: 1em; } +ol.toc li { list-style-type: none; margin: 0; padding: 0; } diff --git a/pandoc-metadata.yaml b/pandoc-metadata.yaml index 303f91c..2acdf83 100644 --- a/pandoc-metadata.yaml +++ b/pandoc-metadata.yaml @@ -3,18 +3,23 @@ # This document contains some pandoc-specific metadata. # # -# This is an inline yaml metadata code block that specifies custom headers and footers -# using latex. Pandoc will probably be the only interpreter that does something useful with it. -# source: https://tex.stackexchange.com/questions/139139/adding-headers-and-footers-using-pandoc # title: "Hack The Hackerspace Manifesto: empowering people to be awesome" author: [Merlijn Sebrechts, Hackerspace Gent] tags: [Do-ocracy, Hackerspace, Self-governance, Structureless Organizations] language: en rights: CC BY-SA 4.0 +toc: true +toc-title: "Table of Contents" +# +# Options specific to Latex (PDF version) +# +links-as-notes: yes +# This is an inline yaml metadata code block that specifies custom headers and footers +# using latex. Pandoc will probably be the only interpreter that does something useful with it. +# source: https://tex.stackexchange.com/questions/139139/adding-headers-and-footers-using-pandoc header-includes: | \usepackage{sectsty} \sectionfont{\clearpage} \usepackage{pdfpages} -links-as-notes: yes ---