TransWikia.com

Centralized bibliography, build/auxiliary folder, and making sure autocomplete still works

TeX - LaTeX Asked by artificial_moonlet on January 28, 2021

Most of us would like to make our lives easier by doing the following:

  1. Outputting auxiliary files to a subfolder (as explained, e.g., here).
  2. Storing all bibliographies in a central directory, where they are updated regularly by Mendeley. (as in, e.g., this post).
  3. Getting autocomplete to work again for cite{} (as in, e.g., this other post).

I am relatively comfortable changing things in Advanced Editor mode, but I don’t get paid to TeX around. This whole process took me quite some time to figure out for my particular set-up. I’d like to propose a post where all these steps are consolidated and the options for different set-ups are laid out clearly. I understand this isn’t a question in the traditional sense, but I think the answers (and perhaps there will emerge a primary answer in the end) would be incredibly helpful to other non-experts.

One Answer

For example, here are the steps for a TeXstudio user on Windows 10 with the latest MikTex who uses PdfLaTeX and BibTeX:

  • Go to Options --> Configure TeXstudio.
  • Under Commands, add --aux-directory=poop to the PdfLaTeX line and poop/% -include-directory=poop to the BibTeX line. (I named my auxiliary folder poop. Replace poop according to your tastes, but be consistent.)
  • Enable Show Advanced Options in the bottom lefthand corner.
  • Go to the Build tab. Under the Additional Search Paths heading, you'll find a line for Log File. Add %cd%poop. This ensures that TeXstudio finds your log file in the auxiliary folder.

The next few steps are about a centralized bibliography maintained by Mendeley.

  • Navigate to C:Program FilesMiKTeXbibtexbiblocal. The local folder may not exist; create it in that case. You'll also want to make sure that Mendeley can actually write here. Right click the folder --> Properties --> Security. Change the permissions for Users: highlight Users, click Edit..., and check Full control.
  • Update the filename database (FNDB) in MikTeX. Depending on which version you have, this could be located in different places. I found it under the 'Tasks' tab.
  • In Mendeley, go to Tools --> Options --> BibTeX. Under BibTeX Syncing, change the path to C:Program FilesMiKTeXbibtexbiblocal. You'll probably have to restart Mendeley before the .bib files show up there.
  • Finally, to make sure that autocomplete still works, you have to tell TeXstudio where to find your amazing centralized directory. Go the Adv. Editor tab and find the Additional Search Paths section. In the Bib Files line, add C:Program FilesMiKTeXbibtexbiblocal.

P.S. I had something strange happen with my BibTeX encoding along the way. I don't know if this is a universal problem. But under the Adv. Editor tab, find the Bibliography section. Make sure Parse BibTeX is checked and that the bib File encoding is set to System.

P.S.S. I think it also a good idea to save all these changes as a profile. Simply go to Options --> Save Profile.

Answered by artificial_moonlet on January 28, 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