在我的MacBook(OSX山獅),我用這個Pandoc命令降價轉換爲PDF格式:降價到PDF使用Pandoc以來的XeTEX棄用
$ markdown2pdf -N -o pandoc_output.pdf --xetex --toc --template=mytemplate.tex myfile.md
但markdown2pdf
不再起作用,並在--xetex
選項markdown2pdf -N -o ../../Desktop/pandoc_output.pdf --xetex --toc --template=mytemplate-headers-garamond_date.tex
已棄用。
如果我這樣做:
$ pandoc -N -o Desktop/pandoc_output.pdf --xetex --toc --template=mytemplate.tex myfile.md
我得到這個:
pandoc: unrecognized option `--xetex'
但如果我拿出--xetex
並做到這一點:
$ pandoc -N -o Desktop/pandoc_output.pdf --toc --template=mytemplate.tex myfile.md
然後我得到這樣的:
pandoc: Error producing PDF from TeX source.
! Package hyperref Error: Wrong driver option `xetex',
(hyperref) because XeTeX is not detected.
See the hyperref package documentation for explanation.
Type H <return> for immediate help.
...
l.3925 \ProcessKeyvalOptions{Hyp}
解決方案是什麼?