Question: I have started to configure VSC as my default latex text editor, using the **"Latex Workshop"** extension.

My question is: How can I make the auxiliary files generated when compiling the project be saved in a separate folder? files (.aux, .bbl, .blg, .fls ...)

I read that this can be done by adding **--aux-directory=FOLDER** to the compile-time statement but I don't know how I can do that in VSC.

Any idea how to do it?

Thank you very much.

Answer: 
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>. The compilation of the file will then be executed using a single command in the Terminal. Once the module has been installed (using pip) you can simply compile the .tex file using lualatex and no BibTeX engine eg. 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

```
**Step One**: On vscode, open the Preferences (UI)

[![enter image description here](https://i.stack.imgur.com/FeqFz.png)](https://i.stack.imgur.com/FeqFz.png)

**Step Two**: search for `latex OutDir`

[![enter image description here](https://i.stack.imgur.com/S6OGU.png)](https://i.stack.imgur.com/S6OGU.png)

**Step Three**: in the field `Latex-workshop Latex: Out Dir`, update the input to `%DIR%/<insert-path>` where `<insert-path>` is the path where you want the output to be placed.

[![enter image description here](https://i.stack.imgur.com/JSuc1.png)](https://i.stack.imgur.com/JSuc1.png)

Note: This solution is relevant for vsCode and the extension '[Latex Workshop](https://github.com/James-Yu/LaTeX-Workshop)'.