[OS X TeX] Finding errors with \input statements in TeXShop?

Richard Koch koch at math.uoregon.edu
Fri May 4 16:41:33 EDT 2012


David and Demitri,


On May 4, 2012, at 1:32 PM, David Derbes wrote:


> I'm writing a book and doing precisely the same as Demitri (so far, 31 sections; each is roughly a half a chapter.)  My main file sets up all the packages used and a couple of new commands and other stylistic stuff (with massive help from Lars Madsen--THANK YOU!), but is probably no more than 120 lines (of which 64 or so are "'input"). When I get an error, the line number cited is for the line number in the relevant chapter (which I usually can work out as I know which chapter I've been working in), NOT the main file. AFAIK I'm using the most up-to-date version of the distribution. 


It isn't clear from your message if TeXShop's "Goto Error" command, on the console and
in the menu bar, takes you to the error in the correct input file. This will happen if
things are set up correctly. Indeed, if the proper input file isn't open, "Goto Error" will
open it and select the line containing the error.

This requires that input files have the appropriate "% !TEX root = …" line at the top. It
also requires that in TeXShop Preferences, under the Engine tab, the various engines
contain the "--file-line-error" flag. To make sure this happens, just push the "Default" button
for the four choices.

Dick Koch


More information about the MacOSX-TeX mailing list