generate_book: Generating a bookdown document or a part of

View source: R/generate_book.R

generate_bookR Documentation

Generating a bookdown document or a part of

Description

The generation of an entire book is performed without any given arguments using the current directory which must be an package book directory or giving a path to the package. A part of the book may be generated when a Rmd file name or a list of is given.

Usage

generate_book(
  input_rmd = NULL,
  book_pkg_dir = getwd(),
  output_format = NULL,
  params = list(),
  output_file = NULL
)

Arguments

input_rmd

Chapter Rmd file name (optional)

book_pkg_dir

Book package directory path (optional, default: current directory)

output_format

String defining the type of document to build (optional); among "bookdown::pdf_document2", "bookdown::pdf_document2", "bookdown::gitbook" (default)

params

A list containing parameters to pass to the Rmd document to parameterize the output or overload existing params in the document

output_file

Output file name to be produced

Value

A success status of the document generation

See Also

build_current_book_part_html, build_current_book_part_pdf

Examples

## Not run: 
generate_book()

generate_book(input_rmd = "07-chap.Rmd")

generate_book(input_rmd = "07-chap.Rmd",
              output_format = 'bookdown::pdf_document2')


## End(Not run)




SticsRPacks/SticsPubRTools documentation built on June 13, 2025, 9:13 p.m.