0

I have several hundreds of line numbers in LaTeX file and I need to get corresponding page numbers on pdf. I would like to perform “command line” forward search, using some Synctex command line interface (that I don't want to develop).

Is there some way to get this using available synctex tools?

Cumbersome solution (without synctex): put \refstepcounter{foo}\label{l-<linenumber>} on each such line and get page number from aux file.

1 Answer 1

1

You can do

synctex -i linenumber:columnnumber:texfile -o pdffile

If I understood synctex correctly, the columnnumber is currently not used, i.e., it can be set to 1.

This command might show multiple locations which could correspond to the line in the source code. (I would typically take the first one).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .