Worked like a charm. Thanks Bastien!
John Hendy <jw.hendy@gmail.com> writes:If your patch comes from a temporary branch, just checkout the master
> Now that the patch is "official", how do I conduct my next git pull since I
> don't really want to commit my modified file in favor of the incoming from the
> git server?
branch (~$ git checkout master) and pull normally with ~$ git pull.
(This is the advantage of working in branches: you'll always be able to
pull from the master branch.)
If your patch comes from the master branch, two cases:
1. you *didn't commit* your changes on your local repo. Then you need
to reset to HEAD and pull:
~$ git reset --hard HEAD
~$ git pull
2. you *did commit* your changes on your local repo. Then you need to
reset to a specific commit (i.e. the one from last pull) and pull:
~$ git reset --hard <commit>
~$ git pull
You can get <commit> with ~$ git log.
Playing with gitk might also help.
http://book.git-scm.com/4_undoing_in_git_-_reset,_checkout_and_revert.html
will give more details.
HTH,
--
Bastien