added correct location detection for win32 git binary

This patch adds code for checking which platform ruby is running on and figures out where the git binary is located even if the platform happens to be mingw32 on windows.


Code is only manually tested, unfortunately, and only works in a mingw32 shell.

However, those other shells didn't work on windows before this anyway... on my machine at least.