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

Re: git-svn segmetation fault

From
Steven Walter <stevenrwalter@gmail.com>
Date
Feb 3, 2008, 02:42 UTC
Message-ID
<20080203024225.GA23647@dervierte>
In-Reply-To
<47A51737.7050905@saville.com>
On Sat, Feb 02, 2008 at 05:21:59PM -0800, Wink Saville wrote:
Show 7 quoted lines
> What steps would be needed to recreate a "local git repo" from the
> "git repo on srvr" that I could use against the svn repo?
>
> I tried a little test, I cloned my git repo on srvr locally to amc-xx
> and added the [svn-remote "svn"] section to amc-xx/.git/config
> and then did a git-svn fetch. From what happened it looks like I
> just did a git svn clone and didn't save any time.

After adding the svn-remote section, you'll want to copy .git/refs/remotes/origin/master to .git/refs/remotes/git-svn. After doing that, "git svn fetch" should see that you have all the needed commits and do a quick rebuild of its metadata.

> Also, a follow up can I create an svn repo from a git repo.

I've not done it, but it should be possible. You would create the new svn repository with a single empty commit (as empty as SVN would allow). Import that revision into your git repository with git-svn. Then you would either rebase or use grafts to make all of your git commits a descendent of that single svn commit. In that way, the next time you run "git svn dcommit" it will see all your local git commits as new commits to send to subversion.

No guarantees though, as I've not tried it.
-- 
-Steven Walter <stevenrwalter@gmail.com>
Freedom is the freedom to say that 2 + 2 = 4
B2F1 0ECC E605 7321 E818  7A65 FC81 9777 DC28 9E8F 
Previous: Wink SavilleNext: Wink Saville
Message 9 of 12 in “git-svn segmetation fault”
  1. Wink SavilleFeb 1, 2008
  2. Wink SavilleFeb 2, 2008
  3. Steven WalterFeb 2, 2008
  4. Wink SavilleFeb 2, 2008
  5. Steven WalterFeb 2, 2008
  6. Wink SavilleFeb 2, 2008
  7. Steven WalterFeb 2, 2008
  8. Wink SavilleFeb 3, 2008
  9. Steven WalterFeb 3, 2008
  10. Wink SavilleFeb 3, 2008
  11. Eric WongFeb 2, 2008
  12. Wink SavilleFeb 2, 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.