Skip to content

Instantly share code, notes, and snippets.

@henningjensen
Created March 4, 2013 21:13
Show Gist options
  • Save henningjensen/5085725 to your computer and use it in GitHub Desktop.
Save henningjensen/5085725 to your computer and use it in GitHub Desktop.
Convert jpg to pdf and merge
http://blog.kaiec.org/2011/02/13/creating-a-pdf-from-images-jpeg/
for i in *.jpg; do sam2p $i $i.pdf; done;
for i in *.jpg.pdf
do sam2p_pdf_scale 595 842 $i $i.a4.pdf
done
pdftk *.a4.pdf cat output result.pdf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment