tompollard / phd_thesis_markdown

Template for writing a PhD thesis in Markdown
MIT License
1.19k stars 551 forks source link

Make it run for newer version of pandoc #123

Open MisterFruits opened 1 week ago

MisterFruits commented 1 week ago

Hi!

I'm having troubles compiling a pdf from your template: make pdf throws make: *** [pdf] Error 43 with the following error in the log:

 ❯ tail pandoc.pdf.log                                                                                                                                                                               [17:36:10]
  tex2pdf.-57db907ea331bc93/input.log.
Error producing PDF.
! LaTeX Error: Lonely \item--perhaps a missing list environment.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...

l.969 \bibitem[\citeproctext]{ref-Cousteau1963}

After make tex diffing the results with what's in the original git repo it seems that every hypertarget calls are missing and here's the problematic section:

@@ -1021,13 +961,12 @@ Aenean dictum nunc id felis rhoncus aliquam.
 \singlespacing
 \setlength{\parindent}{0in}

-\hypertarget{references}{%
-\chapter*{References}\label{references}}
+\chapter*{References}\label{references}
 \addcontentsline{toc}{chapter}{References}

-\hypertarget{refs}{}
-\begin{CSLReferences}{1}{0}
-\leavevmode\vadjust pre{\hypertarget{ref-Cousteau1963}{}}%
+\phantomsection\label{refs}
+\begin{CSLReferences}{1}{1}
+\bibitem[\citeproctext]{ref-Cousteau1963}
 Cousteau Jacques \& Dugan James, 1963. \emph{{The Living Sea: by
 Jacques-Yves Cousteau}}, London: Hamish Hamilton.

I'm kind a noob with all this latex stuff, maybe you see something ?

Notes: installed pandoc with homebrew

MisterFruits commented 1 week ago

Ok, now seeing closed issues, i'll dig in, sorry for confusion

tompollard commented 1 week ago

No problem Victor, it's good to know when people hit issues. The repository isn't really maintained at the moment, so I wouldn't be surprised if there are problems with the build. I'll try to take a look at the repository when I have time to see if I can do some cleaning and updating.

MisterFruits commented 1 week ago

As pointed out by #121 and #122 running a a different version from pandoc 3.1.6.2 leads to errors. Maybe keeping an issue open about that would be great so that newcomers are aware of it ?