If you're having problem with upgrading your Git after upgrading your OSX to Yosemite please follow below what I did to make it work.
This is the error I've got when upgrading my git using Homebrew.
Error: The `brew link` step did not complete successfully
The formula built, but is not symlinked into /usr/local
Here is the solution:
1) First you need to uninstall your current git program
$ brew uninstall --force git
2) change permission of your /usr/local