The other day on mobileread there was a post about combining pdf files. The person has their books in pdf and they are divided by chapters. This got me thinking about the state of the pdf tools in Calibre. There was only one, pdftrim.

I’ve added three new pdf manipulation tools. Merge to combine multiple pdfs into one. Split to split a pdf into multiple files by page. And info to show information about the pdf. Info is especially handy when you want to work with split and need to know how many pages are in the document.

To stop issue with naming conflicts (pdfinfo is used by poppler-utils) and to keep the amount of pdf* names under control I’ve created a git/bzr like wrapper for all of Calibre’s pdf manipulation tools. pdfmanipulate is the base command. A subcommand (see them all with –help) is added after.

$ pdfmanipulate --help
pdfmanipulate command ...

command can be one of the following:
[info, merge, split, trim]

Use pdfmanipulate command --help to get more information about a specific command

Manipulate a PDF.
$ pdfmanipulate merge --help
Usage: pdfmanipulate merge [options] file1.pdf file2.pdf ...

Merges individual PDFs. Metadata will be used from the first PDF specified.