Skip to content

Instantly share code, notes, and snippets.

@paultag
Created April 6, 2012 16:35
Show Gist options
  • Save paultag/2321188 to your computer and use it in GitHub Desktop.
Save paultag/2321188 to your computer and use it in GitHub Desktop.
Create a .GIF of all versions of a .PNG from Git
mkdir ~/os
git log openstatesmap.png | grep commit | awk '{print $2}' | tac > ~/allfifty.rev
I=0; while read foo; do git reset $foo --hard; cp openstatesmap.png ~/os/$I.png; let I=$I+1; done < ~/allfifty.rev
convert -dispose previous -delay 20 -loop 0 `ls *.png | sort -n` openstates.gif
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment