I want to convert a (quite complex) LaTeX file to epub using pandoc with:
pandoc -S file.tex -o file.epub
I have not used markdown in the creation of the tex file, however. When I, now, check the generated epub file I see that all hyperlinks (made by hyperref) are broken and thinks like this appear instead:
Fig. [fig:initial_model]
, s. Table [tab:dis-advantages]
or chapter [ch:findings]
.
A check of the epub file displays the following error message:
Non-registered URI scheme type found in href.
What can I do about it?
tex4ebook filename
. it will create epub2 file by default. You shouldn't need to change your TeX file, unless you use some package which isn't supported bytex4ht
(whichtex4ebook
uses for LaTeX to html conversion)\hyperdef{}{chap-one}{\chapter{One}}\label{chap-one}
and\hyperref[chap-one]{One}
as pandoc does when converting from Markdown, as described here. Maybe you can find some relevanthypersetup
switches in the default LaTeX template (pandoc -D latex
as well.