Skip to content

Instantly share code, notes, and snippets.

@thedarsideofit
Last active February 24, 2018 23:35
Show Gist options
  • Save thedarsideofit/36f6a6791b320c23e0db27c6121b1d68 to your computer and use it in GitHub Desktop.
Save thedarsideofit/36f6a6791b320c23e0db27c6121b1d68 to your computer and use it in GitHub Desktop.
Image Quality Reduction and Watermark with imagemagick
# move to a main image folder
sudo apt-get install imagemagick
# create a redux folder
mkdir ./redux
for f in *.jpg; do convert $f -quality 80 ./redux/$f;done
# move into redux
cd ./redux
#create watermarked folder
mkdir ./watermarked
#i use a logo.png file placed in main image folder
for f in *.jpg; do composite -gravity south -dissolve 30 -gravity center -geometry +0+20 ./../logo.png $f ./watermarked/$f;done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment