Skip to content

Instantly share code, notes, and snippets.

@raspi
Created January 22, 2021 12:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save raspi/ea602ba5ebbf4278c23ed294607347e0 to your computer and use it in GitHub Desktop.
Save raspi/ea602ba5ebbf4278c23ed294607347e0 to your computer and use it in GitHub Desktop.
#!/bin/bash
find . -maxdepth 1 -type f -iname "*.pdf" -exec gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dDownsampleColorImages=true -dColorImageResolution=150 -dNOPAUSE -dBATCH -sOutputFile={}.new.pdf {} \;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment