【问题标题】:Can't install TinyTeX on Windows Server无法在 Windows 服务器上安装 TinyTeX
【发布时间】:2021-08-30 11:48:28
【问题描述】:

这类似于this issue,但提到的解决方案对我不起作用。我尝试通过不同的方法安装 TinyTeX:

  • tinytex::install_tinytex()
  • downloadTinyTeX-0.zip,用tinytex:::install_prebuilt()就可以了
  • 手动提取TinyTeX-0.zipunzip() 有效)并运行install-tl-windows(批处理文件)

在前两种情况下,我有这个错误:

Error in system2("tlmgr", args, ...) : '"tlmgr"' not found
In addition: Warning message:
In extract(pkg, exdir = path.expand(target)) :
  error 1 in extracting from zip file

在第三种情况下,Windows 控制台如下所示:

'\\crc\users\etienne\Desktop\TinyTeX-0\TinyTeX'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.

然后什么都不做就关闭了。

在任何情况下,tinytex::is_tinytex() 都会返回 FALSEtinytex::tlmgr_path() 什么都不返回。

我正在使用 Windows Server 2019 Standard (1809)。我该怎么办?

> sessionInfo()
R version 4.1.0 (2021-05-18)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows Server x64 (build 17763)

Matrix products: default

locale:
[1] LC_COLLATE=French_France.1252  LC_CTYPE=French_France.1252   
[3] LC_MONETARY=French_France.1252 LC_NUMERIC=C                  
[5] LC_TIME=French_France.1252    

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

loaded via a namespace (and not attached):
[1] compiler_4.1.0 tools_4.1.0    tinytex_0.33.1 xfun_0.25 

【问题讨论】:

    标签: r tinytex


    【解决方案1】:

    在这个GitHub issue解决了

    总结:

    • 运行tinytex::install_tinytex(dir = "<path>"),其中<path> 是服务器上的本地文件夹,例如在我的情况下为“C:/Users/etienne/TinyTeX”
    • options(tinytex.tlmgr.path = tinytex:::find_tlmgr("<path>")) 放入您的.Rprofile(您可以使用usethis::edit_r_profile("user") 轻松做到这一点)
    • 重启R
    • 检查tinytex::is_tinytex() 是否为TRUE(例如,您也可以尝试安装带有tinytex::tlmgr_install("booktabs") 的软件包)

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-03-21
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2016-02-23
      • 2020-02-11
      相关资源
      最近更新 更多