Sublime Forum

LaTeXtools build fails on certain files

#1

On my system, build fails on files with basename
starting with a hyphen. Can anyone reproduce this?

  1. take any of your latex files which compiles fine
  2. add a hyphen at the start of the name, like: -aaa.tex
  3. build with the option Latex - pdflatex
  4. build fails with error: Could not read log file -aaa.log

I think this started with latest LaTeXtools update but
I would not swear on it.

While I am at it, could anyone point at some good
explanation of how the build system works, and how
the LaTeXtools build system works? (yes, I read the
official documentation)

Thanx - Piero

0 Likes

#2

If you want that to be fixed you should create an issue at github, which includes your OS and ST version.

The LaTeXTools build system essentially first runs the build command, e.g. latexmk on the file.
Afterwards it reads and parses the log file, extracts the errors, and shows them to the user.

1 Like

#3

PS: “-aaa.tex” is threaded as a command line parameter, so the build is not triggered and the log file not created. Somewhere in the past the call arguments have been switched from absolute paths to switching to directory and using relative paths, because unicode characters in the path have been lead to errors.
We may switch to use “./-aaa.tex” to avoid this very specific problem, but I would anyway recommend not to prefix your filenames with hyphens.

(@ig0774)

1 Like