Bioconductor / BiocStyle

Issues and pull requests for BiocStyle should go here.
12 stars 19 forks source link

Fix BiocStyle & pkgdown interaction #108

Open zeehio opened 4 months ago

zeehio commented 4 months ago

pkgdown https://pkgdown.r-lib.org/ is an R package to build static websites from package documentation and vignettes.

pkgdown evaluates the output format of the vignettes, but it does not use it, since it generates html documents.

However, BiocStyle manually sets the out.format to "latex". This makes pkgdown generate an html file that then is passed to pdflatex, giving an error "\begin{document}" not found. The temporary .tex file contains an html version of the vignette.

imatge

It seems the only reason BiocStyle sets "out.format" to "latex" is to call knit_theme$get(thm)$highlight, by setting "out.format" to its former value everything seems to keep working.

This change restores "out.format", so pkgdown is still able to generate the html files. pdf vignettes still work as expected.