I'm running RStudio (R version 3.6.0) on a Ubuntu 18.04.2 LTS server and trying to compile a pdf using the {papaja}
package. I removed the pre-bundled Tex distribution as recommended (sudo apt-get purge texlive-*
) and installed {tinytex}
.
tinytex::tinytex_root()
# "/home/rstudio/.TinyTeX"
When I try to compile to PDF, I get an error that starts with the search for tlmgr search --file --global '/apa6.cls'
, a file needed for papaja
:
Trying to automatically install missing LaTeX packages...
tlmgr install apa6
You don't have permission to change the installation in any way, specifically, the directory /home/rstudio/.TinyTeX/tlpkg/ is not writable.
This Github issue seems to be related, but if so I'm not understanding the solution.