2012-10-30

Counting Color Pages in PDF Files

Printing books and such in color can be expensive. So here is how to count the color pages using a recent version of GhostScript and a UNIX shell:
gs -o - -sDEVICE=inkcov input.pdf | grep -v "^ 0.00000  0.00000  0.00000" | grep "^ " | wc -l

No comments:

Post a Comment