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

Re: Using git-svn with svnsync mirror

From
PHPhillip Hutchings <sitharus@sitharus.com>
Date
Nov 16, 2010, 07:31 UTC
Message-ID
<AC576A1A-98E4-4710-91B8-7777DBC65B9B@sitharus.com>
In-Reply-To
<20101116042312.GB24344@mail.stoakes.net>
On 16/11/2010, at 5:23 PM, Tim Stoakes wrote:
Show 29 quoted lines
> Phillip Hutchings(sitharus@sitharus.com)@161110-02:08:
>> Hi,
>> 
>> I've got an svnsync mirror of a large repository, and I'm trying to do
>> a git-svn clone from the mirror as the main server is off site. This
>> works well until I try to dcommit or use git svn info.
>> 
>> My investigations show that working_head_info in git-svn doesn't
>> account for using svnsync properties, so it cannot find a log entry
>> that matches a config entry.
>> 
>> My perl isn't good enough to patch this yet, so I was wondering if
>> anyone else had encountered it.
>> 
>> I could change the config URL to match, but I'm worried this will
>> break things.
> 
> You want to use rewriteRoot option so that changing the URL does not
> break things (the URL is stored in each git commit's log).
> 
> I use something like this all the time:
> [svn-remote "svn"]
>  rewriteRoot = svn://svn.foo.com/repo/blah   <-- the master
>  url = svn://svn-mirror.foo.com/repo/somewhere/else/blah  <-- a slave
> 
> If you've imported from the mirror without this option, then you're
> stuck I think. You could work around it by swapping the URLs in the
> rewriteRoot and url fields (essentially rewriting the URLs in the wrong
> order), but this is strictly 'wrong'.

I cloned using --use-svnsync-props, this resulted in the log entries having the correct url to the master, but git-svn being unable to link that url back to the config entry.

Guess I'm in for a recloning then.

-- Phillip Hutchings sitharus@sitharus.com

Previous: Tim Stoakes
Message 3 of 3 in “Using git-svn with svnsync mirror”
  1. Phillip HutchingsNov 16, 2010
  2. Tim StoakesNov 16, 2010
  3. Phillip HutchingsNov 16, 2010

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.