我可以使用 Jekyll 将 GitHub 页面转换为 pdf 吗?

Ema*_*les 3 html jekyll pandoc github-pages

我有一个 GitHub 页面,其中包含我的简历。Github 将 Jekyll 页面呈现为 HTML,生成网站https://emanuelfontelles.github.io/cv/

如何使用 pandoc 甚至 Jekyll 将此网页转换为 pdf?

mb2*_*b21 5

请参阅http://pandoc.org/MANUAL.html#creating-a-pdf,例如:

pandoc https://emanuelfontelles.github.io/cv/ -f html-native_divs -o cv.pdf --pdf-engine=xelatex
Run Code Online (Sandbox Code Playgroud)

-native_divs禁用 div 解析是必要的。因为 pandoc 会寻找类columns,该类有时用于投影仪幻灯片......

或者如果你不喜欢 LaTeX:

wkhtmltopdf https://emanuelfontelles.github.io/cv/ cv.pdf
Run Code Online (Sandbox Code Playgroud)

或者,如果您想使用不同的样式表:

pandoc -o cv.pdf --pdf-engine=wkhtmltopdf --css myprintstyles.css https://emanuelfontelles.github.io/cv/
Run Code Online (Sandbox Code Playgroud)