From: Josef Weidendorfer Date: Wed, 06 Dec 2006 16:44:30 GMT Subject: Re: git pull and merging. Message-ID: <200612061744.31213.Josef.Weidendorfer@gmx.de> In-Reply-To: On Wednesday 06 December 2006 11:05, Aneesh Kumar wrote: > [branch "devel"] > remote = origin > merge = devel > > [....] > Now i thought merge should be local reference. So i changed it to > merge = remotes/origin/devel. > > That also didn't work. > > Then i tried the name of the branch should be indicated as > "refs/heads/devel" . That also didn't work. > > So i guess i am missing something. See man page of git-repo-config: branch..merge When in branch , it tells git fetch the default remote branch to be merged. I assume that the "devel" branch on the remote repo you cloned from is also "devel", more exactly "refs/heads/devel". Now, instead of "git pull", git should default to git pull origin refs/heads/devel:refs/remotes/origin/devel ie. it should update the local tracking branch "refs/remotes/origin/devel" with the remote branch "refs/heads/devel". The tracking branch "refs/remotes/origin/devel" will be merged with current branch afterwards. Now looking at the documentation for branch..merge, it talks about the remote branch, which is "refs/heads/devel" in your case, ie. the first part of the refspec of the full "git pull" command above. So, as you already posted (without explanation, therefore this mail), the config should be [branch "devel"] remote = origin merge = refs/heads/devel However, "devel" alone should work here, as it can be matched with remote "refs/heads/devel". Seems to be a bug, as branch..merge seems to only being compared with the full canonical name in the implementation. Josef