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

After git svn clone master is tied to a branch in svn, howto set master to trunk

From
SBSvenn Are Bjerkem <svenn.bjerkem@googlemail.com>
Date
Mar 11, 2009, 15:17 UTC
Message-ID
<09fb20f5-3722-49d4-9565-95a5b41d15ac@c36g2000yqn.googlegroups.com>

Hi, after performing a $> git svn clone https://svnserver/svn/a/b/c -T trunk/current -t tags - b branches I find that the git master has been tied to one of the branches. It turns out that the highest svn revision number in the repository was tied to that branch.

For historical reasons we have subdirectories in trunk/ on svn, but I
inspected .git/config
[svn-remote "svn"]
        url = https://svnserver/svn
        fetch = a/b/c/trunk/current:refs/remotes/trunk
        branches = a/b/c/branches/*:refs/remotes/*
        tags = a/b/c/tags/*:refs/remotes/tags/*
And I assume it picked up the strange trunk correctly.

I have been googling around for a while looking for instructions how to tell git that when I check out "master" it should be "trunk" from svn and not "branches/next_gen", or more precisely how to move master to trunk from branches/next_gen.

I guess I could solve the problem by modifying a file in trunk on svn and commit so that the trunk will get the highest svn revision number again and redo the clone.

-- Svenn

Next: Svenn Are Bjerkem
Message 1 of 5 in “After git svn clone master is tied to a branch in svn, howto set master to trunk”
  1. Svenn Are BjerkemMar 11, 2009
  2. Svenn Are BjerkemMar 11, 2009
  3. Michael J GruberMar 11, 2009
  4. Svenn Are BjerkemMar 11, 2009
  5. Svenn Are BjerkemMar 11, 2009

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.