Fixed deterministicness of fetchgit with leaveDotGit

The shebang of .git/hooks depended the git's bash, which made the result
depend of that bash's path.