Skip to content

Instantly share code, notes, and snippets.

@ederavilaprado
Created July 25, 2018 22:05
Show Gist options
  • Select an option

  • Save ederavilaprado/5e6049e89a6ef1102a9481f4f64f2ad4 to your computer and use it in GitHub Desktop.

Select an option

Save ederavilaprado/5e6049e89a6ef1102a9481f4f64f2ad4 to your computer and use it in GitHub Desktop.
#!/bin/bash
for file in ./inp/*.jpg
do
outfile=`basename $file .jpg`.png
echo "convert \"$file\" -fuzz 3% -transparent \"#ffffff\" \"./out/$outfile\""
done > script.txt
/usr/local/Cellar/graphicsmagick/1.3.30/bin/gm batch -echo on -feedback on script.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment