I use a windoze box at home and by default it uses the lame microsoft line endings vs linux line endings, which can wreck havoc on bash scripts. So I recently ran a command similar to the following:

find /path/to/files -type f -exec dos2unix {} \;

Much to my dismay, I found that it also converted binary files (.pngs, .gifs, etc), even though, according to the docs, it’s supposed to skip binary files by default. So I had to revert back all the binary files which were converted. Rather than do them one by one I tested and issued the following command (your mileage may vary):

gstatus | fgrep -is png | git checkout -- $(awk '{ print $3 }')