Skip to content

Instantly share code, notes, and snippets.

@thykka
Created October 14, 2014 12:31
Show Gist options
  • Select an option

  • Save thykka/aebdd2397138f84a37dc to your computer and use it in GitHub Desktop.

Select an option

Save thykka/aebdd2397138f84a37dc to your computer and use it in GitHub Desktop.
#!/bin/bash
# This script combines multiple pdf-files into one,
# then compresses it to fit two pages into one.
# pdfjam must be installed.
pdfjoin --outfile /tmp/pdfs-joined.pdf $@
pdfnup --landscape --nup 2x1 --paper a4paper --outfile ./$1-merged.pdf /tmp/pdfs-joined.pdf
rm /tmp/pdfs-joined.pdf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment