Skip to content

Instantly share code, notes, and snippets.

@iperdomo
Created March 11, 2014 07:32
Show Gist options
  • Select an option

  • Save iperdomo/9481142 to your computer and use it in GitHub Desktop.

Select an option

Save iperdomo/9481142 to your computer and use it in GitHub Desktop.
Concatenate PDF files using Ghostscript
#/bin/bash
set -e
gs -q -sPAPERSIZE=a4 -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile="${1}" "${@:2}"
@iperdomo
Copy link
Copy Markdown
Author

usage: contatenate-pdf.sh output.pdf 1.pdf 2.pdf 3.pdf

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment