Skip to content

Instantly share code, notes, and snippets.

@accidentalrebel
Created September 8, 2016 04:24
Show Gist options
  • Save accidentalrebel/c9f211b951fa960178ab81bb99f6ff24 to your computer and use it in GitHub Desktop.
Save accidentalrebel/c9f211b951fa960178ab81bb99f6ff24 to your computer and use it in GitHub Desktop.
Adds a watermark to a group of images in a folder using ImageMagick's Composite Command
@echo off
for %%i in (to_convert/*.jpg) do ( magick convert to_convert/%%i -auto-orient to_convert/%%i && magick composite -watermark 10 -gravity center watermark-white.png to_convert/%%i watermarked/%%i && echo "composite of %%i successful" && del "%cd%\to_convert\%%i" && echo "Successfully deleted %cd%\to_convert\%%i" )
pause
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment