September 24, 2022

Merge multiple pdf files into one pdf file without installing another programme

You can use Ghostscript to merge multiple pdf files into one pdf file.

To merge multiple pdf files into one single pdf file run:

$ gs 
-q \ 
-sPAPERSIZE=letter \ 
-dBATCH \ 
-sDEVICE=pdfwrite \ 
-sOutputFile=merged.pdf \
pdf_file1 \

You can run $ man gs to understand what each option does.

If you don’t know whether Ghostscript is installed on your operating system, on GNU/Linux, you can check by running in your terminal:

$ dpkg -s ghostscript

dpkg is a package manager; the option -s (or –status) prints the status of a programme e.g. whether a program is installed. If so, you should see a line printing:

Status: install ok installed

You can also run:

$ dpkg -s ghostscript | grep installed

grep will print the line that matches keyword installed’.

If you need to install Ghostscript run:

$ sudo apt install ghostscript

Ghostscript was released in 1988 in by L. Peter Deutsch and licensed under GNU Affero General Public License (GNU AGPL).

personal computing command-line interface (cli) gnu linux ghostscript trisquel

No affiliate links, no analytics, no tracking, no cookies. © 2016-2023 Content is licensed under CC BY-NC-SA 4.0 .