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

Re: [PATCH] git svn clone -s was not prefixing 'branches/'

From
Björn Steinbrink <b.steinbrink@gmx.de>
Date
Jan 17, 2009, 12:07 UTC
Message-ID
<20090117120723.GA24549@atjola.homenet>
In-Reply-To
<751e526a0901170339m6471ac84tdb032a090d19d7c6@mail.gmail.com>
On 2009.01.17 11:39:28 +0000, Jon Lim wrote:
Show 32 quoted lines
> Hi,
> 
> Maybe this patch doesn't fix the problem I was having. I will attempt
> to describe it better here.
> 
> I understand that a standard subversion setup is as follows:
> trunk
> branches
> tags
> 
> With the -s option, svn clone should expect this.
> 
> Using the example subversion repository:
> trunk
> branches/RB_1.0
> branches/RB_2.0
> tags/REL_1.0
> tags/REL_2.0
> 
> Currently, using the -s option you get:
> trunk
> RB_1.0
> RB_2.0
> tags/REL_1.0
> tags/REL_2.0
> 
> I think it makes sense to have:
> trunk
> branches/RB_1.0
> branches/RB_2.0
> tags/REL_1.0
> tags/REL_2.0

Why? "trunk" is just a branch like any other branch, too. It's basically just a svn convention that it's not in branches/ but in its own "toplevel" directory. Once imported into git, it's just an ordinary remote tracking branch. It's already pretty well distiguishable from all the other branches due to its name.

What _does_ make sense is to have a common prefix for all the stuff you got from svn, using for example --prefix=svn/. That way you get: svn/trunk svn/RB_1.0 svn/RB_2.0 svn/tags/REL_1.0 svn/tags/REL_2.0

The important part is that those names aren't ambiguous if you have local branch heads called, for example: trunk RB_1.0 RB_2.0

as the svn/ prefix is part of the shortname for the remote tracking branches. So "trunk" is the branch head and "svn/trunk" is the remote tracking branch.

Btw Eric, is there any reason why there's no prefix used by default? Using the name for the svn-remote as the prefix would make a lot of sense to me.

Björn
Previous: Jon LimNext: Eric Wong
Message 3 of 4 in “Re: [PATCH] git svn clone -s was not prefixing 'branches/'”
  1. Eric WongJan 17, 2009
  2. Jon LimJan 17, 2009
  3. Björn SteinbrinkJan 17, 2009
  4. Eric WongJan 18, 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.