Skip to content
Back to formatted view

Raw Message

Message-ID: <alpine.LNX.2.20.2108301410150.15422@salmo.appl-ecosys.com>
Date: 2021-08-30T21:16:17Z
From: Rich Shepard
Subject: bookdown: build using pdflatex from source directory
In-Reply-To: <cf7a37f4-7caa-6f3c-f863-b1bc47fab314@sapo.pt>

On Mon, 30 Aug 2021, Rui Barradas wrote:

> Assuming the file index.Rmd is in R/r4ds-master, try
> bookdown::render_book("R/r4ds-master/index.Rmd", output_format = 
> "bookdown::pdf_book")

Rui,

The build needs to run it from the r4ds-master/ directory. I wondered if
index.rmd was the entry, but didn't try it because the index is at the end
of the book.

The build shows 100% completion, but:
label: unnamed-chunk-67 (with options) 
List of 1
  $ indent: chr "    "

   |......................................................................| 100%
    inline R code fragments

output file: strings.knit.md

Error: Functions that produce HTML output found in document targeting latex output.
Please change the output type of this document to HTML. Alternatively, you can allow
HTML output in non-HTML formats by adding this option to the YAML front-matter of
your rmarkdown file:

   always_allow_html: true

Note however that the HTML output will not be visible in non-HTML formats.

Execution halted
Error in Rscript_render(f, render_args, render_meta, add1, add2) :
   Failed to compile strings.Rmd

And I have no idea how to fix this.

I can try downloading it from github again and see if that makes a
difference.

Many thanks,

Rich