TransWikia.com

How can I save auxiliary-files into an other folder with arara?

TeX - LaTeX Asked by LaRiFaRi on June 20, 2021

I tried to do the following:

% arara: lualatex: {options: -output-directory=.output -aux-directory=.auxiliary}

I did not succeed. I also tried starting the command with -- as well as absolute path with / or .
A nice to have extra would be, that the folders become created if not already existing.

A second question: Will LuaLaTeX know where the auxiliaries are stored in a second run?


I am working on Win XP 64 with MikTeX 2.9

2 Answers

The answer is: it is not possible... but it is not arara's fault.

Infact, the command line --aux-directory is implemented ONLY for a few tools in MiKTeX distribution (it doesn't even exists in TeX Live).

If, from the command line, you run lualatex --help you will get

  The following regular options are understood:

   --8bit                        ignored, input is assumed to be in UTF-8 encoding
   --credits                     display credits and exit
   --debug-format                enable format debugging
   --default-translate-file=     ignored, input is assumed to be in UTF-8 encoding
   --disable-write18             disable write18{SHELL COMMAND}
   --draftmode                   switch on draft mode (generates no output PDF)
   --enable-write18              enable write18{SHELL COMMAND}
   --etex                        ignored, the etex extensions are always active
   --[no-]file-line-error        disable/enable file:line:error style messages
   --[no-]file-line-error-style  aliases of --[no-]file-line-error
   --fmt=FORMAT                  load the format file FORMAT
   --halt-on-error               stop processing at the first error
   --help                        display help and exit
   --initialize                  be iniluatex, for dumping formats
   --interaction=STRING          set interaction mode (STRING=batchmode/nonstopmode/scrollmode/errorstopmode)
   --jobname=STRING              set the job name to STRING
   --kpathsea-debug=NUMBER       set path searching debugging flags according to the bits of NUMBER
   --lua=s                       load and execute a lua initialization script
   --[no-]mktex=FMT              disable/enable mktexFMT generation (FMT=tex/tfm)
   --nosocket                    disable the lua socket library
   --output-comment=STRING       use STRING for DVI file comment instead of date (no effect for PDF)
   --output-directory=DIR        use existing DIR as the directory to write files in
   --output-format=FORMAT        use FORMAT for job output; FORMAT is 'dvi' or 'pdf'
   --[no-]parse-first-line       disable/enable parsing of the first line of the input file
   --progname=STRING             set the program name to STRING
   --recorder                    enable filename recorder
   --safer                       disable easily exploitable lua commands
   --[no-]shell-escape           disable/enable write18{SHELL COMMAND}
   --shell-restricted            restrict write18 to a list of commands given in texmf.cnf
   --synctex=NUMBER              enable synctex
   --translate-file=             ignored, input is assumed to be in UTF-8 encoding
   --version                     display version and exit

Alternate behaviour models can be obtained by special switches

  --luaonly                run a lua file, then exit
  --luaconly               byte-compile a lua file, then exit

As you can see, --aux-directory is not present.


You can obtain something similar depending on your editor, for example WinEdt and TeXMaker have a similar option. See this thread: Is there a way to configure pdflatex to make all but the .tex and .pdf files hidden files?.

Correct answer by karlkoeller on June 20, 2021

This may be a little late, but for all of those that still deal with these issues:

I have specifically created a python module for saving the auxiliary files that are generated by LaTeX and BibTeX engines into a desired folder. On my GitHub site are more informations: https://github.com/amrane99/LaTeXCompiler. Once the module has been installed (using pip) you can simply compile the .tex file using lualatex and no BibTeX engine as follows -- the generated files will be stored in the .aux_files folder --:

LaTeXCompiler -file <full_path_to_file>.tex 
              -tex_engine lualatex -no_bib_engine -aux_folder .aux_files

I hope this helps with the common issue of saving the auxiliary files in a separate folder so the working directory is always kept clean.

Answered by Amin Ranem on June 20, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP