【发布时间】:2018-09-05 17:51:42
【问题描述】:
我正在使用 Rstudio 生成带有 bookdown 的文档。不幸的是,我必须使用 Windows 并且没有 xelatex。
如何阻止 bookdown 尝试生成 compile_main.tex?
我只想要 HTML
我只想知道在 index.Rmd 文件的 YAML 标头中放入什么以仅选择 HTML 作为输出格式。似乎 list this 应该在 output: part 中,但我没有在 Yihui 的书中找到这个问题。
Error: Failed to compile _main.tex.
In addition: Warning message:
running command '"xelatex" -halt-on-error -interaction=batchmode "_main.tex"' had status 127
Please delete _main.Rmd after you finish debugging the error.
Execution halted
Exited with status 1.
【问题讨论】:
-
除了下面的正确答案:您可以使用 tinytex 包轻松安装包含 xetex 的 TeX 安装。
-
我尝试了 install.packages('tinytex') tinytex::install_tinytex() 但安装尝试从我的管理员限制的站点下载。我要求打开网站。我刚刚又试了一次。它似乎奏效了。 tinytex:::is_inytex() > TRUE 。这是一个奇迹!