Merging PDFs into a book

I needed this to combine chapters of a PDF book into one single pdf.


pdftk 01.pdf 02.pdf 03.pdf 04.pdf 05.pdf 06.pdf 07.pdf 08.pdf 09.pdf 10.pdf 11.pdf 012.pdf 013.pdf 014.pdf 015.pdf 016.pdf 017.pdf 018.pdf 019.pdf 020.pdf 021.pdf 022.pdf 023.pdf 024.pdf 025.pdf 026.pdf 027.pdf 028.pdf 029.pdf 030.pdf 031.pdf 032.pdf 033.pdf 034.pdf 035.pdf 036.pdf 037.pdf 038.pdf 039.pdf 040.pdf 041.pdf 042.pdf 043.pdf 044.pdf 051.pdf 050.pdf cat output book.pdf[/code]

So the code is:

pdftk pdf1 pdf2 pdf3... cat output outputfilename[/code]

If you want verbose output:

pdftk 001.pdf 002.pdf cat output out.pdf verbose[/code]

You are reading this post on Joel G Mathew’s tech blog. Joel's personal blog is the Eyrie, hosted here.