This compiles and produces a pdf of the given (sub)section only. But the great feature is that I can now replace main_file.tex with for instance sections/section1.tex or sections/section1/subsection1-1.tex. To compile the full document - this autocompiles when any of the subfiles changes. Similarly I can have deeper levels of subsections.įrom main_folder, I typically run something like latexmk -outdir=output_files -pdf -pvc -interaction=nonstopmode main_file.tex Main_file.tex typically looks like: \documentclass Output_files (useful to have a separate folder for the output files) Macros.tex (here I write short macros and import the larger macros below) References.bib (autogenerated from my Zotero library) Preamble.sty (importing packages and adjusting settings as I need it) To illustrate, I typically use a folder setup like: main_folder For instance, I would go as far as saying it's good practice to place macros and TikZ figures in individual files (at least when they have a certain size). Also, split files into multiple files when they get too long, or there is a natural way to divide the content. First of all, I strongly recommend using the subfiles package (see setup below). What I find more important in the beginning, is to focus on good file organization - this will save you a lot of time and frustration later. And the appearance can always be adjusted later - that's somewhat the point of LaTeX in my opinion. I just start writing the content, and import packages as soon as I need them. Just an opinion relevant to the post - personally I don't like to start with a large template.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |