git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Getting git-svn to recognize branchpoints?

From
davetron5000 <davetron5000@gmail.com>
Date
Jun 6, 2008, 19:07 UTC
Message-ID
<a12182cd-2cd3-42a6-b3b4-f99907576741@d77g2000hsb.googlegroups.com>

I was given a branch in an SVN repo to work on. My plan is to merge it with trunk in Git to indicate how much easier it would be to use Git.

Unfortunately, Git doesn't seem to realize that my branch is a branch from SVN's trunk. For example, I have made no changes to file foo.c

The main trunk has changes to foo.c
When I merge, those changes show up as conflicts.

gitk doesn't show any branch points, and I'm thinking that Git just doesn't see the branches as they are in SVN.

The sha-1 of the branch commit from SVN shows up in gitk when I've checked out my branch, but not if I have the trunk checked out (though a git log DOES show it).

Here's what I did to initially set this up (I'm working on $SVNROOT/ branches/FOO):

git-svn init ssh://www.theirrepo.com/svnroot git-checkout -b local-trunk trunk git-branch local-foo FOO git-checkout local-foo

git-svn dcommit on local-foo sends changes to FOO, if on local-trunk, they are sent to trunk in SVN git-svn rebase gets changes from FOO or trunk, as appropriate

Here's my .git/config:
[core]
    repositoryformatversion = 0
    filemode = true
    bare = false
    logallrefupdates = true
[svn-remote "svn"]
    url = svn+ssh://davec@svn.theirrepo.com/svnroot
    fetch = trunk:refs/remotes/trunk
    branches = branches/*:refs/remotes/*
    tags = tags/*:refs/remotes/tags/*
Any ideas?
Next: Steven Walter
Message 1 of 3 in “Getting git-svn to recognize branchpoints?”
  1. davetron5000Jun 6, 2008
  2. Steven WalterJun 7, 2008
  3. davetron5000Jun 7, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.