1

Following this previous post regarding a conflict between \includeonly and the hyperref package, here is another problem I found with \includeonly.

With the following mwe,a first compilation pdflatex main.tex yields a full pdf where everything is fine. Though, after uncommenting the line with \includeonly a new run of pdflatex main.tex yields a pdf with an extra blank page...

The issue is related to the use of either the minitoc or float package.

I am aware of this fix proposed in an older post but it creates a conflict with the hyperref package post.

Do you see any way around it ?

Here is main.tex:

\documentclass[]{article}
\usepackage{float}
\usepackage{minitoc}

% my choice of chapter
    %\includeonly{chapitre_1}

\begin{document}
    % plan de cours
        \include{description}
    % chapitre 1
        \include{chapitre_1}
        \include{chapitre_1_exercices}
    % chapitre 2
        % ...
\end{document}

and where description.tex is:

\newpage
\section*{Plan de cours pour la session d'}
Le cours \dots

chapitre_1.tex is:

\newpage
\section{Chapitre 1}

\label{chap_1}
% table des matières
\newpage
\subsection{Introduction}
    Contenu du chapitre\dots
\newpage
    page supplémentaire pour afficher les numéros de page

and chapitre_1_exercices.tex is:

\newpage        
\subsection{Exercices d'application}
    Liste d'exercices\dots
  • Try adding \usepackage{newclude} to your preamble. (This was in the link you provided.) – erik Apr 18 '18 at 14:47
  • This does not seem to change anything... I still get the extra blank page... – Alain Apr 18 '18 at 16:38
  • Even if you delete your .aux files? – erik Apr 18 '18 at 17:58
  • @erik yes, I still have my extra blank page after deleting all the .aux files and recompiling... – Alain Apr 18 '18 at 20:59
  • Try without loading the minitoc package. – erik Apr 18 '18 at 21:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.