Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide easier way to access latex log file #663

Closed
hadley opened this issue Dec 19, 2018 · 5 comments
Closed

Provide easier way to access latex log file #663

hadley opened this issue Dec 19, 2018 · 5 comments
Milestone

Comments

@hadley
Copy link
Member

hadley commented Dec 19, 2018

The only way I could find to capture the log file was this hack:

options("bookdown.post.latex" = function(x) {
  xfun::write_utf8(parent.frame()$x, parent.frame()$f)
  tinytex::latexmk(f, "xelatex", clean = FALSE)
  file.copy("_main.log", "latex.log")
  x
})

I wanted needed this to find broken references, so I'd also be happy to accept any solution that made it easier to check that I hadn't cross-referenced a section that didn't exist.

@yihui
Copy link
Member

yihui commented Dec 20, 2018

I'll work on this in the tinytex package. When there are broken cross-references, I guess I shouldn't delete the log file, and perhaps should also parse the log to warn against these references in R. Thanks for the suggestion!

@hadley
Copy link
Member Author

hadley commented Dec 20, 2018

I think it might be reasonable to never delete the log file?

@yihui
Copy link
Member

yihui commented Dec 20, 2018

Yeah, that sounds like a good idea, too.

@yihui yihui added this to the v0.9 milestone Dec 20, 2018
@yihui
Copy link
Member

yihui commented Dec 20, 2018

Should be fixed now via

devtools::install_github('yihui/tinytex')

clrpackages pushed a commit to clearlinux-pkgs/R-tinytex that referenced this issue Jan 12, 2019
… Package fontspec Error: The font "latinmodern-math" cannot be found.'

Yihui Xie (5):
      start the next version
      the error message about the missing font could be '! Package fontspec Error: The font "latinmodern-math" cannot be found.'
      these packages have been included in pkgs-custom.txt (i.e. the default installation)
      fix rstudio/bookdown#663: if a log file contains warnings, don't delete it
      CRAN release 0.10
@github-actions
Copy link

github-actions bot commented Nov 6, 2020

This old thread has been automatically locked. If you think you have found something related to this, please open a new issue by following the issue guide (https://yihui.org/issue/), and link to this old issue if necessary.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 6, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants