r - 安装自定义 TeX 包

标签 r latex r-markdown quarto tinytex

我正在尝试安装自定义 Latex 包 ( this Beamer template )。我尝试在 ...\AppData\Roaming\TinyTeX\texmf-local\ 下创建一个新目录,复制 .sty 文件并使用 tlmgr update --self - 刷新 Tinytex all tlmgr path add fmtutil-sys --all,但是当我调用 pksewhich mypackage.sty 时它仍然不显示.

最佳答案

问题Install package manually #377 TinyTeX github repo 上描述了一种实现此目的的方法。

步骤是

  1. 创建texmf文件夹

    mkdir ~/texmf
    
  2. 然后创建TeX目录结构

    mkdir -p ~/texmf/tex/latex
    
  3. 然后将custom-latex-package文件夹放在~/texmf/tex/latex目录下

  4. 然后添加到 TeX 的“搜索路径”

    tlmgr conf auxtrees add ~/texmf
    

然后kpsewhich beamerthemesintef.sty 返回

c:/Users/User/texmf/tex/latex/custom_pkg/beamerthemesintef.sty

这种方法的一个警告是 @Yihui pointed out也就是说,升级或重新安装TinyTeX后,您需要重复第4步。

关于r - 安装自定义 TeX 包,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/74921228/

相关文章:

r - 将 LaTeX 与 R markdown 和 pandoc 相结合

latex - 如何在 LaTeX 表格中通过冒号对齐时间?

r - 在 Knitr 或 RMarkdown Beamer 中并排的表格和数字

r - 在rstudio/knitr文档中导入常见的YAML

r - 有没有更优雅的方法来使用 lubridate 将两位数的年份转换为四位数的年份?

r - 针织/Rmd : Adding title page and text when converting to MS Word

c++ - 构建 R 包 : "Found ' rand', 可能来自 'rand' (C)"检查包时注意

java - R XLConnect : loadWorkbook warnings - "An illegal reflective access operation has occurred"

c# - 找不到初始化文件 gs_init.ps

r - 如何在 rmarkdown 中正确对齐数学方程?