CompileLatexDir: Compiling function

Description Usage Arguments Details Value Author(s) Examples

View source: R/latexmkCompilation.R

Description

This function calls latexmk, which must be part of the system commands, a directory where tex files are found and outputs their pdf and other things in the pdf.dir.out The functions CompileLatexDirEXAM and CompileLatexDirHW are identical wrappers of the same function, CompileLatexDir. Do not use them, they are just kept for "backwards" compatibility

Usage

1
2
3
4
5
6
7
8
CompileLatexDir(pdf.dir.out, latex.dir.in, engine = "xelatex",
  compile.dir = NULL, extracmdoptions = NULL)

CompileLatexDirEXAM(pdf.dir.out, latex.dir.in, engine = "xelatex",
  compile.dir = NULL, extracmdoptions = NULL)

CompileLatexDirHW(pdf.dir.out, latex.dir.in, engine = "xelatex",
  compile.dir = NULL, extracmdoptions = NULL)

Arguments

pdf.dir.out

Directory where the pdf output will be sent to

latex.dir.in

Directory where all the tex files are found.

engine:

Engine to use when compiling. Currently the options are xelatex, lualatex, latex and pdflatex

xelatex is the default value. However, if the value is not recognized, pdflatex is used instead.

compile.dir:

Directory from which compilation is invoked, if not specified, the directory we are compiling will be from where we do it. (This is specially usefull since we want to mantain the same relative paths from the main file).

Details

Write the tex files relative paths to other files as to be read from the directory in which latex.dir.in is found This function is intended to be use to compile a bunch of files which are stemmed from an original one. That is why the directory

Value

None

Author(s)

Alejandro Recuenco alejandrogonzalezrecuenco@gmail.com

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
input_folder <- system.file(
    "extdata",
    "ExampleTexDocuments",
    package = "TexExamRandomizer")


TexExamRandomizer::CompileLatexDir(
    pdf.dir.out = tempdir(),
    engine= "pdf",
    latex.dir.in = input_folder,
    extracmdoptions = "-time")

TexExamRandomizer documentation built on May 2, 2019, 3:18 a.m.