# latex > Compile a DVI document from LaTeX source files. > More information: . - Compile a DVI document: `latex {{source.tex}}` - Compile a DVI document, specifying an output directory: `latex -output-directory={{path/to/directory}} {{source.tex}}` - Compile a DVI document, exiting on each error: `latex -halt-on-error {{source.tex}}`