Compress PDF offline with ghostscript #
I found this great tool to compress pdf (python script) from the command line.
Make sure you have ghoscript installed. If not just run
brew install ghoscript
How to #
Copy source files from
https://github.com/hkdb/cpdf to your bin directory (that’s defined in your env) eg.
/usr/local/bin if you are on OSX.
Then from your favorite terminal, just use one of the commands described in the
readme of the project.
cpdf ebook in.pdf out.pdf
Thank you hkdb!