我如何知道我的 LaTeX 文件是否有错误?

我如何知道我的 LaTeX 文件是否有错误?

我已经在 TeXShop 中更改了设置,以便只有出现错误时才会显示控制台。但是,控制台总是弹出。我该如何确定错误数量?

梅威瑟:

\documentclass[12pt,a4paper]{article}
\begin{document}
a
\end{document}

控制台输出是:

This is pdfTeX, Version 3.14159265-2.6-1.40.20 (TeX Live 2019) (preloaded format=pdflatex)
 restricted \write18 enabled.
entering extended mode
(./MWE.tex
LaTeX2e <2020-02-02> patch level 1
L3 programming layer <2020-02-08>
(/usr/local/texlive/2019/texmf-dist/tex/latex/base/article.cls
Document Class: article 2019/12/20 v1.4l Standard LaTeX document class
(/usr/local/texlive/2019/texmf-dist/tex/latex/base/size12.clo))
(/usr/local/texlive/2019/texmf-dist/tex/latex/l3backend/l3backend-pdfmode.def)
No file MWE.aux.
[1{/usr/local/texlive/2019/texmf-var/fonts/map/pdftex/updmap/pdftex.map}]
(./MWE.aux) )</usr/local/texlive/2019/texmf-dist/fonts/type1/public/amsfonts/cm
/cmr12.pfb>
Output written on MWE.pdf (1 page, 8482 bytes).
SyncTeX written on MWE.synctex.gz.
Transcript written on MWE.log.

日志输出为:

This is pdfTeX, Version 3.14159265-2.6-1.40.20 (TeX Live 2019) (preloaded format=pdflatex 2020.2.10)  4 MAR 2020 13:13
entering extended mode
 restricted \write18 enabled.
 file:line:error style messages enabled.
 %&-line parsing enabled.
**MWE.tex
(./MWE.tex
LaTeX2e <2020-02-02> patch level 1
L3 programming layer <2020-02-08>
(/usr/local/texlive/2019/texmf-dist/tex/latex/base/article.cls
Document Class: article 2019/12/20 v1.4l Standard LaTeX document class
(/usr/local/texlive/2019/texmf-dist/tex/latex/base/size12.clo
File: size12.clo 2019/12/20 v1.4l Standard LaTeX file (size option)
)
\c@part=\count167
\c@section=\count168
\c@subsection=\count169
\c@subsubsection=\count170
\c@paragraph=\count171
\c@subparagraph=\count172
\c@figure=\count173
\c@table=\count174
\abovecaptionskip=\skip47
\belowcaptionskip=\skip48
\bibindent=\dimen134
)
(/usr/local/texlive/2019/texmf-dist/tex/latex/l3backend/l3backend-pdfmode.def
File: l3backend-pdfmode.def 2020-02-03 L3 backend support: PDF mode
\l__kernel_color_stack_int=\count175
\l__pdf_internal_box=\box45
)
No file MWE.aux.
\openout1 = `MWE.aux'.

LaTeX Font Info:    Checking defaults for OML/cmm/m/it on input line 2.
LaTeX Font Info:    ... okay on input line 2.
LaTeX Font Info:    Checking defaults for OMS/cmsy/m/n on input line 2.
LaTeX Font Info:    ... okay on input line 2.
LaTeX Font Info:    Checking defaults for OT1/cmr/m/n on input line 2.
LaTeX Font Info:    ... okay on input line 2.
LaTeX Font Info:    Checking defaults for T1/cmr/m/n on input line 2.
LaTeX Font Info:    ... okay on input line 2.
LaTeX Font Info:    Checking defaults for TS1/cmr/m/n on input line 2.
LaTeX Font Info:    ... okay on input line 2.
LaTeX Font Info:    Checking defaults for OMX/cmex/m/n on input line 2.
LaTeX Font Info:    ... okay on input line 2.
LaTeX Font Info:    Checking defaults for U/cmr/m/n on input line 2.
LaTeX Font Info:    ... okay on input line 2.
[1

{/usr/local/texlive/2019/texmf-var/fonts/map/pdftex/updmap/pdftex.map}]
(./MWE.aux) ) 
Here is how much of TeX's memory you used:
 362 strings out of 481255
 6171 string characters out of 5918611
 236091 words of memory out of 5000000
 15703 multiletter control sequences out of 15000+600000
 532636 words of font info for 25 fonts, out of 8000000 for 9000
 1141 hyphenation exceptions out of 8191
 24i,4n,21p,136b,97s stack positions out of 5000i,500n,10000p,200000b,80000s
</usr/local/texlive/2019/texmf-dist/fonts/type1/public/amsfonts/cm
/cmr12.pfb>
Output written on MWE.pdf (1 page, 8482 bytes).
PDF statistics:
 12 PDF objects out of 1000 (max. 8388607)
 7 compressed objects within 1 object stream
 0 named destinations out of 1000 (max. 500000)
 1 words of extra memory for PDF output out of 10000 (max. 10000000)

相关内容