4

I'm very new to LaTeX and I'm working with a large document created by several other people. It's been very difficult to parse, (some sections have indexing, inconsistent formatting, etc).

What's the best way to add commenting/documentation to guide the next person who will be working on the document? Is there any sort of standard most people use? My google searches have proved useless but its entirely possible that's just because I don't know what keywords to look for.

KiwiS
  • 41

1 Answers1

2

I think there is currently no "official" coding guideline: see the discussion on Are there any coding style guidelines for LaTeX?.

In my option it is very useful to structure the document by including the chapters/sections from separate files:

  • base directory
    • documents.tex
    • includes (folder)
      • section_01.tex
      • section_02.tex
      • ...
    • figures
      • figure_01.png
      • figure_02.svg
      • ...

All contributors can add a new chapter/section in the includes folder and add a corresponding include command in the main document.tex file. In order to change the styling of the complete document or to add a custom command, you can add this in the main file.

I try to add comments between different sections of each file. Separate the custom commands from the usepackage commands or the document information (like title etc). Furthermore I suggest to add a comment after each usepackage command to explain the reason why it is used here.

I hope this is helpful.

Fabian
  • 31