public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
From: BP Jonsson <bpjonsson-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: pandoc-discuss <pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
Subject: Re: Need pandoc to create a latex file from some html files
Date: Tue, 28 Nov 2023 19:24:19 +0100	[thread overview]
Message-ID: <CAFC_yuRTCLE6Ja85ELO4rUXz1q5aUtO0MBTPXwbXyiVOPTy0Ew@mail.gmail.com> (raw)
In-Reply-To: <aaec9ee1-c839-4dd6-bd56-c41657991b6en-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 2792 bytes --]

You should be good just doing

pandoc index.html manual.html errata.html -o manual.pdf

or -o manual.tex (or manual.ltx if you prefer) if you want the LaTeX file.
Pandoc should be able to guess the formats from the extensions.

One caveat though: if the three HTML files contain external links to each
other you probably want to convert them to internal links. It could be done
with a filter but the easiest way is probably to convert to an intermediate
markdown file and polish that in a text editor, then convert that markdown
file to LaTeX/HTML. It also has the advantage that you can inspect what
Pandoc makes of the HTML.

Also it is probably better to let LaTeX (re)build the table of contents.



Den mån 27 nov. 2023 01:13almaghfuur lahu <budikusasi-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> skrev:

> How do we create a new PDF file by having pandoc to create a latex file
> from some html files under one directory merely, i.e. not recursively, as
> it's just acquired from a server directory to display a rather simple,
> small reference documentation?
> $ ls
> cover.png  errata.html  index.html  manual.html
>
>
> index.html is actually containing table of contents, each line of which
> is a link to a location in the file manual.html, and also some words index
> , each line of which is a link to a location in manual.html
>
> It has line:
>
> <IMG SRC="cover.png" ALT="" TITLE="click to buy the book" BORDER=1
> ALIGN="left" HSPACE=12>
>
> manual.html is the content or body of the reference manual
>
> errata.html is the catch up of corrections needed to care in this
> reference manual
> How to accomplish to obtain its one analogous latex file from which its
> PDF file can be created the best, most efficient way ?
>
> --
> You received this message because you are subscribed to the Google Groups
> "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pandoc-discuss/aaec9ee1-c839-4dd6-bd56-c41657991b6en%40googlegroups.com
> <https://groups.google.com/d/msgid/pandoc-discuss/aaec9ee1-c839-4dd6-bd56-c41657991b6en%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/CAFC_yuRTCLE6Ja85ELO4rUXz1q5aUtO0MBTPXwbXyiVOPTy0Ew%40mail.gmail.com.

[-- Attachment #2: Type: text/html, Size: 10046 bytes --]

      parent reply	other threads:[~2023-11-28 18:24 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-27  0:12 almaghfuur lahu
     [not found] ` <aaec9ee1-c839-4dd6-bd56-c41657991b6en-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2023-11-27  8:35   ` Need pandoc to create a latex file, " Bastien DUMONT
2023-11-28  2:37     ` almaghfuur lahu
2023-11-28 18:24   ` BP Jonsson [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAFC_yuRTCLE6Ja85ELO4rUXz1q5aUtO0MBTPXwbXyiVOPTy0Ew@mail.gmail.com \
    --to=bpjonsson-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).