Created
November 7, 2012 02:54
-
-
Save jingoro/4029324 to your computer and use it in GitHub Desktop.
PDF Tricks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for f in *.pdf; do | |
echo "Extracting first page of $f..." | |
gs -sDEVICE=pdfwrite -dNOPAUSE -dBATCH -dSAFER \ | |
-dFirstPage=1 -dLastPage=1 \ | |
-sOutputFile="${f}_first.pdf" \ | |
"$f" | |
done | |
gs -sDEVICE=pdfwrite -dNOPAUSE -dBATCH -dSAFER \ | |
-sOutputFile=Combined.pdf \ | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment