Closed maecky closed 2 years ago
This could be a latexmk
bug. The most recent version (change log) has a note about changing the handling of output directories. Given that I would suggest upgrading if possible.
Thanks for your answer. I did update latexmk, the issue stays the same. Tried it with texlive and miktex (manually installed the latest version of latexmk).
Is S:
a network drive or a removable drive?
You could also try executing latexmk
from the command line to help determine if it is a latexmk
or a atom-latex
issue. From a command shell try:
S:
cd Documents\LatexTemplates\Report
latexmk -pdf -outdir=build main.tex
This issue has been marked as stale because due to inactivity. It will be closed in 7 days if no further activity occurs.
Sorry for the late response:
S:
is a VeraCrypt volume.
I tried your suggested command from a command line. From there everything works perfectly fine (except the PDF file stays in the build
folder but I suppose that's supposed to be?).
That means, it seems to be an atom-latex
issue?
Is the VeraCrypt volume a physical drive?
Also, can you try using the DiCy builder so we can see if the issue is builder specific?
No, the VeraCrypt volume is a file that is mounted.
The DiCy builder works (sometimes). All files are generated in the .build folder and then 3 files are copied to the root: main.pdf main.gz main.yaml
If I delete the .build folder and the generated files, I have to restart Atom - otherwise, the files aren't created again. There is no error message, it just doesn't work after deleting the files and folders.
I'm getting a similar issue on Windows 7. I was getting status code 1 (could not find scriptEngine: perl.exe), but after adding perl path to atom-latex settings I'm getting status code 2 with a similar error as OP.
Basically it looks like latexmk prepends the build directory instead of appending:
Cannot write file 'build/C:\Users\-----\-----\manuscript.aux'
Running latexmk manuscript.tex -pdf -auxdir=dir
works fine from terminal.
Edit: Note that removing Output Directory setting in atom-latex allows build to proceed properly
Edit2: I suspect it has to do with jobState.jobName
. I can produce a similar error by calling latexmk with arguments like this package does and setting -jobname=/path/to/manuscript
. Since latexmk argument -cd
is passed, the path portion of the jobname is superfluous.
Edit3: Ignore Edit2, jobName
is irrelevant. The error appears to be a latexmk bug. This package calls latexmk like this:
latexmk -interaction=nonstopmode -f -cd -file-line-error -synctex=1 -pdf -outdir="build" "C:\Users\---\---\manuscript.tex"
I confirmed this fails with the same error when calling from terminal. However, the following works:
latexmk -interaction=nonstopmode -f -cd -file-line-error -synctex=1 -pdf -outdir="build" C:/Users/---/---/manuscript.tex
Note the quotes are removed from the file and the direction of slashes is changed. I'm not sure if this package can or should handle this case :/
This issue has been marked as stale because due to inactivity. It will be closed in 7 days if no further activity occurs.
First of all, I want to say thank you for the awesome work you are doing. I like the plugin a lot but today I ran into an issue:
I want my generated files to be redirected to a folder called "build". Therefore, I put "build" into the "Output Directory" settings.
On Windows 10 with Latesmk version 4.52c this is not working. The folder gets created in my project but then an error occurs:
The odd thing is, the S:\Documents\LatexTemplates\Report\build got created but after that, somehow the path gets messed up?