I'm a little over a week into a git immersion program. Let me just say that git's reputation of being a little arcane (okay, more than a little) and having a steep learning curve is 100% deserved.
One thing that would mitigate things is if git would give you feedback when you tell it to do nonsense. But it doesn't. Here's me trying to get machine B to always merge the debug branch from machine A when I pull:
232 git config branch.debug.remote origin 234 git config branch.master.remote origin 236 git config branch.master.remote origin/debug
All of these commands completed silently. None accomplished what I wanted. In the end I renamed master to old and debug to master to avoid having to fight it. Then I blew away my working copy and re-cloned because those config statements had created a new problem that I didn't know how to undo.
I'm sure the git virtuosos out there will know what was wrong. That's not the point. The point is that the tool gave me no feedback. It was like git was telling me, "Figure it out yourself. Or don't. I don't care." Which is par for the course with my git experience so far.
Comments
$ git pull
You asked me to pull without telling me which branch you
want to merge with, and 'branch.foo.merge' in
your configuration file does not tell me either. Please
name which branch you want to merge on the command line and
try again (e.g. 'git pull <repository> <refspec>').
See git-pull(1) for details on the refspec.
If you often merge with the same branch, you may want to
configure the following variables in your configuration
file:
branch.foo.remote = <nickname>
branch.foo.merge = <remote-ref>
remote.<nickname>.url = <url>
remote.<nickname>.fetch = <refspec>
See git-config(1) for details.
======
So you have to do something like this:
git config branch.foo.remote = origin
git config branch.foo.merge = refs/heads/master
Now, everytime you pull from the local foo branch it will merge with origin/master
(for reference: http://article.gmane.org/gmane.linux.kernel/542867 )
The mailing list answer was something along the lines of 'this is an edge case that rarely happens' rather than 'ok, this reply can be improved'. That sucks.