LinuxCommandLibrary

pdflatex

TLDR

Compile LaTeX to PDF

$ pdflatex [document.tex]
copy
Compile in non-stop mode
$ pdflatex -interaction=nonstopmode [document.tex]
copy
Compile with shell escape
$ pdflatex -shell-escape [document.tex]
copy
Output to specific directory
$ pdflatex -output-directory=[outdir] [document.tex]
copy
Specify output name
$ pdflatex -jobname=[output] [document.tex]
copy

SYNOPSIS

pdflatex [options] file

DESCRIPTION

pdflatex compiles LaTeX documents directly to PDF format. It's part of TeX Live and MiKTeX distributions, and the most common way to produce PDFs from LaTeX source.
The tool processes .tex files, handling typesetting, cross-references, and including graphics. Multiple runs may be needed for complete document processing.

PARAMETERS

-interaction= mode

Interaction mode (batchmode, nonstopmode, scrollmode, errorstopmode).
-output-directory= dir
Output directory.
-jobname= name
Set output name.
-shell-escape
Enable shell commands.
-halt-on-error
Stop at first error.
-file-line-error
Show file:line:error format.
-synctex= n
Generate SyncTeX data.

CAVEATS

Often needs multiple runs for references. Shell escape has security implications. Package errors can be cryptic. Auxiliary files accumulate.

HISTORY

pdfTeX was developed by Han The Thanh starting in 1996, extending TeX to output PDF directly. pdflatex combines this with the LaTeX format. It became the standard LaTeX workflow, largely replacing DVI output.

SEE ALSO

latex(1), xelatex(1), lualatex(1), bibtex(1)

Copied to clipboard