Pdftk merge

Share on:

"PDFtk - The PDF Toolkit. PDFtk is a simple tool for doing everyday things with PDF documents. It comes in three flavors: PDFtk Free, PDFtk Pro, and our original command-line tool PDFtk Server."

In a prior blog post, the PDFTK utility was installed.

Working with PDF can often produce multiple files that would be easier to manage if they were combined. Learn how to use the utility to merge mutliple files into a PDF.

  1. Move the required files into the convert folder e.g.
1mv *.pdf ~/temp/convert
  1. Move to the convert directory
1cd ~/temp/convert
  1. Use PDFTK to merge files into a new output PDF
1pdftk chapter-1.pdf chapter-2.pdf chapter-3.pdf output book.pdf 

The file book.pdf will contain the pdf files included in the command. Note the order in the book.pdf will honour the order used. So the book.pdf will feature, chapter-1 to chapter-3.