Hi Anton, On Thu, Apr 26, 2012 at 4:05 PM, Anton Korobeynikov <anton at korobeynikov.info> wrote:> Sebastian, > >> I just saw that the git branch remotes/origin/release_31 has been created >> for llvm. Unfortunately it is missing the right context: right now I can only >> see 11 patches in that branch with the last patch having no parent. >> >> Could somebody please fix this? > This looks like git-svn bug. If anyone knows "the cure" I'd be happy > to apply it.In your svn section of llvm/.git/config, you can specify how to map the svn branches to different name spaces, something like this: [svn-remote "svn"] [...] branches = branches/*:refs/remotes/origin/* fetch = branches:refs/remotes/origin I would also change "branches = branches/*:refs/remotes/origin/*" into something like "branches = branches/*:refs/remotes/branches/*" Thanks, Sebastian -- Qualcomm Innovation Center, Inc is a member of Code Aurora Forum
> In your svn section of llvm/.git/config, you can specify how to map > the svn branches to different name spaces, something like this: > > [svn-remote "svn"] > [...] > branches = branches/*:refs/remotes/origin/* > fetch = branches:refs/remotes/origin > > I would also change "branches = branches/*:refs/remotes/origin/*" > into something like "branches = branches/*:refs/remotes/branches/*"This is exactly what was done on llvm.org. Here is an example fron clang.git: fetch = trunk:refs/heads/master tags = tags/{RELEASE_20,RELEASE_21,RELEASE_22,RELEASE_23,RELEASE_24,RELEASE_25,RELEASE_26,RELEASE_27,RELEASE_28,RELEASE_29,RELEASE_30,RELEASE_31}:refs/heads/svn-tags/* branches branches/{release_20,release_21,release_22,release_23,release_24,release_25,release_26,release_27,release_28,release_29,release_30,release_31}:refs/heads/* -- With best regards, Anton Korobeynikov Faculty of Mathematics and Mechanics, Saint Petersburg State University
Hi Anton, git-svn got confused at the branch point for the release_31: I see that the current release_31 branch has been created on r155051 as a copy of r155050 from trunk, and r155050 is actually removing an older release_31 branch: Revision 155050 Author: void Date: Wed Apr 18 16:38:33 2012 CDT (11 days, 20 hours ago) Log Message: Removing old release_31 branch for rebranching. This "old release_31 branch" was created on r154899: Revision 154899 Author: void Date: Mon Apr 16 21:00:08 2012 CDT (13 days, 16 hours ago) Log Message: Creating release_31 branch Here is how I fixed this in my local git repo: looking at the last commit to trunk r155049, before the "new release_31" has been created: commit bdcfb7663a2a62fd52a14dbeaa076423c719ec2d Author: Bill Wendling <isanbard at gmail.com> Date: Wed Apr 18 21:38:12 2012 +0000 Add a flag to rebranch if we need to. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk at 155049 91177308-0d34-0410-b5e6-96231b3b80d8 and the first commit that appears on the release_31 branch: commit 0d2807ae7060f6b0ffdf65b8606b2a6c61e1018a Author: Bill Wendling <isanbard at gmail.com> Date: Fri Apr 20 20:32:47 2012 +0000 Merging r155230: ------------------------------------------------------------------------ r155230 | void | 2012-04-20 13:31:44 -0700 (Fri, 20 Apr 2012) | 1 line Modify the sh-bang to run out-of-the-box for FreeBSDes. ------------------------------------------------------------------------ git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_31 at 155231 91177308-0d34-0410-b5e6-96231b3b80d8 we can ask git to consider bdcfb7663a2a62fd52a14dbeaa076423c719ec2d as the parent of 0d2807ae7060f6b0ffdf65b8606b2a6c61e1018a like this: # cd llvm # echo "0d2807ae7060f6b0ffdf65b8606b2a6c61e1018a bdcfb7663a2a62fd52a14dbeaa076423c719ec2d" > .git/info/grafts and then we can make this change permanent by rewriting the commits in the release_31 branch: # git filter-branch -- bdcfb7663a2a62fd52a14dbeaa076423c719ec2d..remotes/origin/release_31 Thanks, Sebastian -- Qualcomm Innovation Center, Inc is a member of Code Aurora Forum