On 04/07/13 14:59, Thomas Schwinge wrote: > Hi! > > On Wed, 3 Jul 2013 09:54:58 -0700, Jason Merrill <ja...@redhat.com> wrote: >> On 07/03/2013 02:47 AM, Thomas Schwinge wrote: >>> OK, that of course works, but from the wiki page I got the idea that it >>> explicitly was meant to merge these together. So assuming this used to >>> work in the past, I wonder what so that it no longer does; such as Git >>> allowing such duplicates merging in the past, and/or was the intersection >>> of refs/remotes/* and refs/heads/* meant to be the empty set (then I >>> assume the merging would work, too), but no longer is? >> >> Hmm, it looks like I wrote that up without actually doing it myself, >> oops. I'll correct the wiki. > > Hmm, seems the change you've done: > > fetch = refs/heads/*:refs/remotes/origin/* > fetch = refs/remotes/*:refs/remotes/origin/remotes/* > > ..., is not ideal either: using »git fetch --verbose --prune« I now see > all the refs being downloaded -- and then immediatelly pruned again. :-/ > > Would the following be an appropriate variant? Seems to work fine, but > "disturbs" the regular Git refs namespace a bit? > > fetch = refs/heads/*:refs/remotes/upstream/* > fetch = refs/remotes/*:refs/remotes/upstream-remotes/* >
Jason, AFAIU you addressed this issue in the gcc wiki r108 ( http://gcc.gnu.org/wiki/GitMirror?action=diff&rev1=107&rev2=108 ) on 2013-07-11. However, I ran into the same problem with 'The various release branches': ... $ for f in 4_8 ; do git config --add remote.origin.fetch refs/remotes/gcc-$f-branch:refs/remotes/origin/gcc-$f-branch; done $ git remote update Fetching origin fatal: refs/remotes/origin/gcc-4_8-branch tracks both refs/heads/gcc-4_8-branch and refs/remotes/gcc-4_8-branch error: Could not fetch origin ... Following the changes you made in 'Fetching all branches', the command becomes: ... git config --add remote.origin.fetch refs/remotes/gcc-$f-branch:refs/remotes/svn/gcc-$f-branch ... I could try that out, but apparently something more is needed: ... Unfortunately, this doesn't work well with the git-svn configuration set up above, because it expects the branches to be in remotes/origin. One way to deal with this is to switch git-svn to use remotes/svn instead and adjust your local branches to use remotes/svn for their upstream. ... Can you translate the last sentence into shell/git command(s)? Thanks - Tom