Questions tagged [subfiles]

{subfiles} is about a class and package for multi-file projects in LaTeX

Filter by
Sorted by
Tagged with
0 votes
0 answers
26 views

Use tex subfile as appendix with separate TOC and frontpage

I have two files that are very similar; their preambles are very similar. They are also both full documents with their own chapters, front pages and tables of content. I want to use one of those files,...
Luctia's user avatar
  • 101
2 votes
2 answers
48 views

Demoting unnumbered section using newenvironment not working for subfile

I am trying to export a tex using subfile into a main tex file. The file structure is the same for both the main file and subfile. The importing of the subfile is an addendum. The leveldown of the ...
Ozooha Ozooha's user avatar
4 votes
2 answers
57 views

Referencing ExPex example from a different subfile?

Is there any way I can get subfiles to correctly reference ExPex example numbers? Say I had a main file which contained two subfiles. One subfile contains an ExPex example, and the other contains a ...
geordiekidd's user avatar
1 vote
1 answer
74 views

latexmkrc and subfiles

I have a LaTeX-Project that is split into multiple files using the package subfiles. The project has the following structure: main.tex .latexmkrc lib/custom-class.cls lib/custom-package.sty foo/bar....
GeF's user avatar
  • 13
1 vote
1 answer
43 views

Subfile compilation fails bibliography

I am working on overleaf, and I am trying to set up a large project. When I compile main.tex the citation appears, but when I do the local compile of content/mini.tex they do not. Any suggestions? My ...
Carlos Mougan's user avatar
2 votes
2 answers
145 views

How to make bibliography to work in subfiles of a subfile?

I am writing a long report that needs the help of the subfiles package to break it into individual sections. It works like a charm until I further split one of the subfiles into two. Previously, the \...
Shixi's user avatar
  • 23
1 vote
2 answers
56 views

Add separate \maketitle to subfile which only executes when the subfile is compiled independently

I'm writing a document with multiple files, and I hope to add titles to them like so: %%% main.tex \documentclass{article} \usepackage{subfiles} \title{Main} \begin{document} \maketitle Some text \...
Canyon's user avatar
  • 269
1 vote
0 answers
65 views

Packages used in subfiles not working in main.tex

I'm following Overleaf example of 'subfiles' ... and also some examples of the 'verse' and the 'song' packages The subfiles work well but when called by main.tex the song package does not work ...
AWE's user avatar
  • 111
0 votes
0 answers
99 views

Subfiles and biblatex

I've been trying to compile a multi-file project using biblatex and a .bib to handle the bibliography. I have an output document, but all my citations appear undefined. I want to use the \cite command ...
Alejandro Salas's user avatar
1 vote
0 answers
43 views

How can i add a beamer LateX file to the main LateX file? [closed]

I am trying to add a Beamer LateX file to my main LateX file using the command subfile. After some research, I found the \usepackage{beamerarticle} package that actually helped me insert it into the ...
Γιάννης Γιαννάκος's user avatar
1 vote
2 answers
60 views

Better way to subfile multiple files with similar titles?

I have a set of lecture notes and each lecture is contained within a subfile, and the main file contains a list of all the lectures like so: \subfile{lec-1} \subfile{lec-2} % more files labeled lec-X \...
Revise's user avatar
  • 355
0 votes
0 answers
40 views

Please suggest which method is correct to proceed

I'm using the following tags to generate a project: \documentclass{book} \begin{document} \frontmatter \include{fm} \mainmatter \include{ch01} ... \include{ch10} \backmatter \bibliographystyle{...} \...
GowriSaro's user avatar
  • 458
1 vote
1 answer
464 views

Overleaf - Compiling multiple .tex files into multiple outputs (alternatively, nesting document classes?)

Clarification: I am looking for a way to automatically run pdflatex on multiple .tex files to produce multiple separate .pdf files when I click the Recompile button in Overleaf. I have multiple .tex ...
L Duran's user avatar
  • 13
3 votes
1 answer
226 views

The best/correct order of loading hyperref, cleverref and subfiles packages

I got it from overleaf that the subfiles package is best loaded last in the preamble. Besides, it is known that hyperref is recommended to loaded last too. In another answer, I got that Load varioref ...
HsiL's user avatar
  • 43
2 votes
1 answer
279 views

What is the correct way to import files within subfiles?

The subfiles docs explains that it handles path issues when main files and subfiles are in different directories and subfiles contain paths relative to their own directories using the \import package. ...
socialscientist's user avatar
3 votes
2 answers
111 views

How do (relative) paths work with the subfile package?

I am trying to understand how (relative) paths need to be used with the subfiles package. In particular, it's not clear how content that I usually would include with \include, \input, \includegraphics,...
socialscientist's user avatar
2 votes
1 answer
232 views

Citation Problems when using subfiles

I am aiming for a multifile Latex document and I am working on it in Overleaf. I would like each chapter to have separate bibliography sections (this can be done apparently with the chapterbib package)...
Heath's user avatar
  • 207
1 vote
1 answer
108 views

Loading a preamble from a separate file than the main file with the subfiles package. When I compile the main.tex everything works but not subfile

I have a document with a very long preamble in the separate file general.tex. The main.tex looks something like \documentclass[10pt, letterpaper]{article} \input{general.tex} \usepackage{subfiles} \...
Alex Cong's user avatar
1 vote
1 answer
138 views

biblatex and subfiles: New type of previously reported error

Let me start off by saying that I am aware that variants of this question have been asked many times before (at least in 1, 2, 3, 4, 5, 6, 7, 8), yet despite trying all of the solutions I've read, my ...
Shady Puck's user avatar
2 votes
1 answer
288 views

Subfiles not finding `main.tex` reliably

The minimal working example could not be simpler: I have a main.tex file like so: \documentclass{article} \usepackage{subfiles} \begin{document} \subfile{Subfiles/subfile} \end{document} and a ...
Jan Matula's user avatar
2 votes
1 answer
91 views

Is it possible to have a search path for subfiles?

Similar to how the graphicspath works, would it be possible to create a search path subfilespath for .tex files instead of images? For example, given a folder structure as below. - Main - FolderA ...
Steven's user avatar
  • 153
1 vote
1 answer
29 views

\subfile expands robust commands (so differs from \input in that respect)

I'm overloading _ as a non-breakable dash in nonmath, and this poses no problem with \input: \documentclass{article} \usepackage{babel} \let\subscr=_ \catcode`_=\active \DeclareRobustCommand_{\ifmmode\...
Michaël's user avatar
  • 1,354
2 votes
1 answer
753 views

Is there a way to always compile the main document?

I am using overleaf and I have a main document and several subfiles. Is there a way of always having the main file compile even if I have selected and I am editing subfiles? Cheers in advance, Blake
Blake Rowan's user avatar
3 votes
2 answers
129 views

Does subfiles work with memoir?

I am considering whether to to try to use subfiles with memoir, biber, and xelatex. Before I try, I wanted to ask: does this kind of setup work with subfiles? Usually I would just try it myself and ...
Alex Roberts's user avatar
  • 1,369
1 vote
1 answer
140 views

use bib2gls in individually compiled subfiles

I am trying to use the glossaries-extra package with record (using bib2gls) option for a symbols list in a long document where each chapter can be compiled individually using the subfiles package. My ...
mayonnaise's user avatar
1 vote
1 answer
112 views

subfiles "Command already defined" problem

I have the following problem: Using a combination of the subfiles package, 4 files, a subdirectory, and input in the preambles, and where the 'outer' file subfile-imports the 'inner' file in the ...
Jon's user avatar
  • 131
3 votes
1 answer
160 views

Graphicspath with several paths not working when only defined in the subfile

I have a main document which calls several modules and also uses images from upper folders, this is the structure of the folders: Icons Common Covers Test All main.tex Module subfile.tex ...
fancy_docs's user avatar
0 votes
1 answer
415 views

Title page not showing up in subfile{} when included in main.tex

I am compiling a different documents of article class type and I am using a main tex file of report class to compile it into one pdf file. I used subfile{} to do so but the \maketitle{} page in ...
Vaishnav's user avatar
1 vote
1 answer
212 views

One pdf file for each chapter in addition to the global pdf

For my lecture notes, I have a big tex file containing \include commands (one for each chapter). Is there a way to typeset in one go : the whole file: i.e. all the files appearing in the includeonly (...
jowe_19's user avatar
  • 855
1 vote
1 answer
188 views

A error about subfiles and tikzpicture

I have a main.tex and a subfile. Subfile.tex file works independently, but when I run it with main.tex, the soft clip code gives an error. Is there any way to fix this? Where am i doing wrong? My main....
Mehmet Onat's user avatar
1 vote
1 answer
500 views

Bibliography with subfiles

I am writing my PhD thesis in Overleaf and having issues with bibliography while using subfiles command. Ideally I would like one bibliography right at the end of the thesis instead of different ...
User12's user avatar
  • 11
0 votes
0 answers
19 views

Error when trying to input an external file with xltabular package `\hline ->\noalign` [duplicate]

I am trying to stack several tables one on another. For this I am using xltabular packages. I want to input text from another file. The following code works without problem when removing / commenting ...
ecjb's user avatar
  • 883
1 vote
1 answer
118 views

First page number misplaced when using subfile and loadgeometry

In a document (memoir class), I need to have a title page with large margins compared to the rest of the document. To do that, I use \savegeometry/\loadgeometry. However, if I include this title using ...
tobiasBora's user avatar
  • 7,803
1 vote
1 answer
252 views

Bibliography imported from main and subfiles

I have a bib file that I need several subfiles to have access to. Currently the file structure is: project main.tex Bib.bib Chapters Chapter1 Chapter1.tex I can ...
andrew's user avatar
  • 115
1 vote
0 answers
112 views

Names of the files using subfiles package

I was wondering if there is a way to include with the subfiles package, files (in a main tex file) that don't have english names, especially in my case greek, but generally in other languages? I have ...
Νικολέτα Σεβαστού's user avatar
1 vote
0 answers
34 views

Why would a \subfile{} call not return? [duplicate]

Tex presents no errors. Output Calling Sub2.tex. Sub2.tex entered. Calling Sub1.tex. Sub1.tex entered. Sub1.tex completed. Directory structure ./main.tex ./Sub2.tex ./Sub1.tex main.tex \...
DevJoe's user avatar
  • 11
1 vote
1 answer
296 views

Bibtex issues with subfile

Good day I am attempting to cite in a subfile using a global BibTeX file but I keep getting the following error You have cited something which is not included in your bibliography. Make sure that the ...
Susan-l3p's user avatar
0 votes
1 answer
239 views

My natbib referencing is not working on one particular PC and I don't know why

I am writing my PhD thesis, which is split into multiple chapter subfiles with a masterfile that combines them all for convenience of editing. I have attempted to implement citations in the subfiles ...
Matt Rogers's user avatar
1 vote
1 answer
105 views

hyperref and bibunit: Keep the destination of the cite-link in the same bibunit

I have a rather big and complex document with several bibunits and recurring citations. By default, all citations target the first appearance of a reference in a bibliography, leading to awkward jumps ...
Sir Cornflakes's user avatar
1 vote
2 answers
208 views

Possible subfiles/setspace issues

I seem to be having difficulty preventing my document from overwriting \doublespacing commands. I have a document using a subfiles structure (a Main.tex) that calls a number of subfile .tex's for each ...
Jerome's user avatar
  • 173
1 vote
1 answer
128 views

Tikz-graphic gets squashed in subfigure

I try to display two tikz-plots in the same figure. But one gets totally squeezed into a small area. Here I use the same file in both subfigures, an get this result: \usepackage{subcaption} \...
dba's user avatar
  • 639
1 vote
1 answer
174 views

Subfiles is not ignoring \end{document}

As far as I understand the subfiles for use in the subfiles package should all end with \end{document}, so that they can be built independently. However, I'm finding that, in order for each of my ...
Ben's user avatar
  • 11
2 votes
1 answer
525 views

subfiles: bibliography not found in chapters

I'm using subfiles to split my document into multiple files, one per chapter. It works great, except for bibliography: if I compile the main document, the items are found, but if I compile a chapter ...
tobiasBora's user avatar
  • 7,803
1 vote
1 answer
128 views

\newgeometry not applying to the last page of a subfile, but only in main document

I'm working on a two-sided document which collates a number of files using the subfiles package, some of which require wider margins for margin notes. However, the \newgeometry command consistently ...
cora's user avatar
  • 13
0 votes
1 answer
677 views

How can I enforce creation of *.aux files?

I want to write a thesis using subfiles and xr for external references. I use subfiles because that allows me to compile chapters separately without having to compile the whole thesis. My problem is ...
Insa's user avatar
  • 1
1 vote
0 answers
100 views

Multiple bibliographies - one for each group of subfiles [closed]

I'm writing my thesis, and to allow working on separate sections more easily, I have broken the document down into subfiles. I have multiple subfiles per chapter, but I want to have one bibliography ...
JoshD's user avatar
  • 11
1 vote
1 answer
62 views

Lettrine in a subfile produces weird alignment

I am trying to typeset a pretty document, and with that comes the need for lettrine. When I use it in my main.tex, everything works as expected. When I use it in a subfile, it works properly when I ...
Sotiris's user avatar
  • 37
0 votes
0 answers
55 views

Consistent biblatex citation numbering when using subfiles

I am using subfiles to split my project in individual parts. For the bibliography I am using biblatex. I only want a single bibliography for the whole document. But would like the citation references ...
Jan Hajer's user avatar
  • 844
0 votes
0 answers
229 views

Can a subfile have its own preamble without the standalone package?

Can a subfile have its own preamble without the standalone package? I tried adding a preamble to a subfile, basically just a different font and it did not work. Is there a way to do so (because I hear ...
dictatemetokcus's user avatar
0 votes
1 answer
388 views

What is the use of subfile custom document class?

One way to use subfiles is: \documentclass[11pt]{book} \usepackage{subfiles} \begin{document} ... \subfile{finename} ... \end{document} Another way is: \documentclass[main.tex]{subfiles} \begin{...
dictatemetokcus's user avatar

1
2 3 4 5 6