views:

240

answers:

2
+2  Q: 

Latex Output

When I compile a latex file, it produces also a .txt, .bbl, .aux files. They are not useful as I can delete them without harm. My question is what are these files for and how can I opte not to generate them when I compile the .tex file?

+8  A: 

Those files are useful and represent the output of the multiple-pass typesetting process. If you delete them, you'll need to rerun LaTeX to regenerate them. Quite often, you'll see a LaTeX workflow that looks something like this:

  1. Run LaTeX (finds all the bibliographical references, figure entries, etc.)
  2. Run BibTeX (creates an initial set of text for the bibliographic entries)
  3. Run LaTeX (populates the document with bibliography, figure references)
  4. Run LaTeX (general good luck: there are some corner cases when references need two passes to fully populate)

That said, once you have a printable document (.dvi, .pdf, .ps, etc.), you can delete those temporary files until you need to edit the LaTeX source again.

This answer to another question breaks down what each pass is doing (from the point of a bibliography).

Bob Cross
+2  A: 

From bluesky.com

"The .aux (auxiliary) file is where LaTeX stores all the information about the counters (like section numbers), footnotes, bibliography entries, reference marks, and anything else that LaTeX may need to keep track of. This file is written over whenever a file is typeset by LaTeX. Whenever a document is typeset LaTeX reads this file to get the information it need, and writes to it after typesetting is completed. This is why changes in the counters will not take effect until LaTeX is run twice, because the .aux file is not up to date the first time. The .bib file is where all the bibliography information is kept. You can either make this file yourself, or you can use BibTeX to create the file. The .toc file contains all the information needed to create the Table of Contents. This file is created when LaTeX sees the command \tableofcontents, and the section names, numbers and page numbers are all read from the .aux file."

Neil