Created
April 29, 2020 19:07
-
-
Save jcaxmacher/a1f321e2b66644daba77456ecfabbc17 to your computer and use it in GitHub Desktop.
Nice PDFs from Markdown
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\usepackage{sectsty} | |
\sectionfont{\clearpage} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\usepackage{fancyvrb,newverbs,xcolor} | |
\definecolor{Light}{HTML}{F4F4F4} | |
\let\oldtexttt\texttt | |
\renewcommand{\texttt}[1]{ | |
\colorbox{Light}{\oldtexttt{#1}} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pandoc input.md \ | |
-f gfm \ | |
--include-in-header chapter_break.tex \ | |
--include-in-header inline_code.tex \ | |
--highlight-style pygments.theme \ | |
-V linkcolor:blue \ | |
-V geometry:a4paper \ | |
-V geometry:margin=2cm \ | |
-V mainfont="DejaVu Serif" \ | |
-V monofont="DejaVu Sans Mono" \ | |
--pdf-engine=xelatex \ | |
-V fontsize=12pt \ | |
-o output.pdf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"text-color": null, | |
"background-color": "#f8f8f8", | |
"line-number-color": "#aaaaaa", | |
"line-number-background-color": null, | |
"text-styles": { | |
"Other": { | |
"text-color": "#007020", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Attribute": { | |
"text-color": "#7d9029", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"SpecialString": { | |
"text-color": "#bb6688", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Annotation": { | |
"text-color": "#60a0b0", | |
"background-color": null, | |
"bold": true, | |
"italic": true, | |
"underline": false | |
}, | |
"Function": { | |
"text-color": "#06287e", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"String": { | |
"text-color": "#4070a0", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"ControlFlow": { | |
"text-color": "#007020", | |
"background-color": null, | |
"bold": true, | |
"italic": false, | |
"underline": false | |
}, | |
"Operator": { | |
"text-color": "#666666", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Error": { | |
"text-color": "#ff0000", | |
"background-color": null, | |
"bold": true, | |
"italic": false, | |
"underline": false | |
}, | |
"BaseN": { | |
"text-color": "#40a070", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Alert": { | |
"text-color": "#ff0000", | |
"background-color": null, | |
"bold": true, | |
"italic": false, | |
"underline": false | |
}, | |
"Variable": { | |
"text-color": "#19177c", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"BuiltIn": { | |
"text-color": null, | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Extension": { | |
"text-color": null, | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Preprocessor": { | |
"text-color": "#bc7a00", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Information": { | |
"text-color": "#60a0b0", | |
"background-color": null, | |
"bold": true, | |
"italic": true, | |
"underline": false | |
}, | |
"VerbatimString": { | |
"text-color": "#4070a0", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Warning": { | |
"text-color": "#60a0b0", | |
"background-color": null, | |
"bold": true, | |
"italic": true, | |
"underline": false | |
}, | |
"Documentation": { | |
"text-color": "#ba2121", | |
"background-color": null, | |
"bold": false, | |
"italic": true, | |
"underline": false | |
}, | |
"Import": { | |
"text-color": null, | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Char": { | |
"text-color": "#4070a0", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"DataType": { | |
"text-color": "#902000", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Float": { | |
"text-color": "#40a070", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Comment": { | |
"text-color": "#9c9c9c", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"CommentVar": { | |
"text-color": "#60a0b0", | |
"background-color": null, | |
"bold": true, | |
"italic": true, | |
"underline": false | |
}, | |
"Constant": { | |
"text-color": "#880000", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"SpecialChar": { | |
"text-color": "#4070a0", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"DecVal": { | |
"text-color": "#40a070", | |
"background-color": null, | |
"bold": false, | |
"italic": false, | |
"underline": false | |
}, | |
"Keyword": { | |
"text-color": "#007020", | |
"background-color": null, | |
"bold": true, | |
"italic": false, | |
"underline": false | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Credit - https://learnbyexample.github.io/tutorial/ebook-generation/customizing-pandoc/