During the past few years, I have become a fan of LaTex. I write documents using LaTex whenever possible for ease of formatting, inserting images and version control.
Today I’ve found an easy way to merge PDF files using LaTex. Suppose I want to attach the first three pages of file2.pdf to the end of file1.pdf and thus create a new PDF file, we can use the LaTex source below and compile it with pdflatex:
By now I’ve found two natural but minor limitations of this approach: (1) it cannot properly handle bookmarks and (2) it will not intellegently update the page numbers shown in pagefoot.