[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Combine PDF files



On 2025-09-24 11:15:46 +0200, Toni Mas Soler wrote:
> Maybe the most simple option, but it works for me when I want
> concatenate PDF's:
> 
> gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite -sOutputFile=$OUTPUTFILE.pdf
> $FILE_IN1.pdf $FILE_IN3.pdf

If the goal is just to join PDF files, using Ghostscript is a bad idea,
as it may give unexepected results. If you must use it, you should do a
manual check:
  * Check that some pages have not been rotated
    (or use -dAutoRotatePages=/None).
  * Check the quality of images.
  * Check that the text part is still correct for you.

Ghostscript will not just join PDF files, it will reconstruct a PDF
file from scratch, after interpreting the input files. One advantage
is that it may give a smaller file (but it may also be bigger), and
make validity errors disappear. But you need to check the result.

-- 
Vincent Lefèvre <vincent@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / Pascaline project (LIP, ENS-Lyon)


Reply to: