I have a main tex file:



this is main document.

and a subsidiery file included in the main file:

This is a chapter in another file.

enter image description here

An IDE like texmaker can compile only the main file and is not smart enough to have a multiple file project. Is there a way to make all subsidiary files compilable?

This will make it easier to fix them.

  • 1
    Are you referring to making the subfile compilable on their own? Which might be problematic when it comes to references to other subfiles. Texmaker has the master file feature, such that you can be in a subfile, hit compile, and it will compile the master file. – daleif Oct 25 '15 at 6:32
  • @daleif I was thinking about a similar procedure to adding header files in C programming. adding a header more than one time does not produce a problem there. With it I think I can make all files runnable. Where is the master file option in texmaker? – Minimus Heximus Oct 25 '15 at 6:43
  • 1
    Are you searching for standalone package and class? It does something like that. – user11232 Oct 25 '15 at 6:46
  • 1
    Another option is using the subfiles package: tex.stackexchange.com/a/261180/74960 – MarcoG Oct 25 '15 at 8:37
  • 2
    why not use \include and \includeonly{chapter2} ? – David Carlisle Oct 25 '15 at 9:18

Browse other questions tagged or ask your own question.