Introduction

Sometimes, to manage multiples pdf files the best solution is to merge them into one bigger. You may find either a web or cloud-based solution but if some of these files contain personal information, sharing them externally allowing servers from outside to read and process this sensitive data is not the best option. In such cases, there are command-line tools that are able to process them on your computer and provide a unified pdf file with minial effort. PDFUnite is one of such command-lines tools.

Installation

In most Linux distributions, the package manager handles the installation. In Debian distributions, a simple apt (or apt-get) does the heavy lifting for you.

sudo apt install poppler-utils

Arch-derived distributions can use pacman:

sudo pacman -S poppler

Or RPM distrutions like fedora with dnf:

sudo dnf install poppler-utils

If you are unlucky and need to compile and build it yourself, here is the URL where you will find all the essential information. POPPLER rendering Library.

Basic use

PFDUnite is really simple. To merge more than one pdf file, the command is:

$ pdfunite first.pdf second.pdf output.pdf

where:

  1. first.pdf and second.pdf are the files to be merged into one.
  2. output.pdf is the destination pdf file.

Reduce size

In cases where the final file is very large, it is possible to find a way to reduce its size by following this URL: Linux shell script to reduce PDF file size.