Hello,
I occasionally have to download a bunch of web pages, turn them into PDF, and merge them all into a single PDF file.
Do you know of a way to automate that?
1. From list, download web pages including pictures: wget ?
2. Convert each into PDF: cpdf/mutool/qpdf?
3. Merge all into single PDF:
Code
@echo off
setlocal enabledelayedexpansion
set f=
for %%f in (*.pdf) do set f=!f! "%%f"
echo %f%
mutool merge -o full.pdf -O compress %f%
Thank you.
Have you considered generating an .epub book with
dotepub and converting it to a .pdf file with Calibre?
Or just having the epub!
Quote Shohreh
Hello,
I occasionally have to download a bunch of web pages, turn them into PDF, and merge them all into a single PDF file.
Do you know of a way to automate that?
1. From list, download web pages including pictures: wget ?
2. Convert each into PDF: cpdf/mutool/qpdf?
3. Merge all into single PDF:
Code
@echo off
setlocal enabledelayedexpansion
set f=
for %%f in (*.pdf) do set f=!f! "%%f"
echo %f%
mutool merge -o full.pdf -O compress %f%
Thank you.
You can feed a list to wget by appending the "--input-file=" option to the command line. E.g. I have a file (wget-list):
Code
I'd do:
Code
wget --input-file=wget-list
Very useful, especially when downloading multiple files.
Thanks for the infos. I forgot to say I'd rather a desktop solution than web-based.
After feeding wget a list of URLs, HTML pages can then be turned into individual PDFs with
wkhtmltopdf, and merged into a single PDF with cpdf/qpdf/mutool.