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

Re: GSOC Proposal draft: git-remote-svn

From
ASAndrew Sayers <andrew-git@pileofstuff.org>
Date
Apr 2, 2012, 23:20 UTC
Message-ID
<4F7A3450.7000302@pileofstuff.org>
In-Reply-To
<20120402222958.GD13969@burratino>
On 02/04/12 23:29, Jonathan Nieder wrote:
Show 13 quoted lines
> Hi Andrew,
> 
> Andrew Sayers wrote:
>> On 02/04/12 09:30, Florian Achleitner wrote:
> 
>>> The remote helper has to convert the foreign protocol and data (svn) to the 
>>> git-fast-import format.
>>
>> As discussed on IRC, I'd like to see some discussion of solutions that
>> use plumbing directly (e.g. git-commit-tree) if you choose to focus on
>> branch import.
> 
> Do you mean that fast-import is not a plumbing command?

Sorry, that wasn't clear. I meant commands that just expose a single primitive bit of functionality (like git-commit-tree) instead of those that present an abstract interface to the whole git machinery (like git-fast-import). I'm not sure what the right word for that would be?

I agree it's possible to use fast-import for this problem, but it seems
like it's redundant after svn-fe has already loaded everything into git.
 For example, if svn-fe loaded three revisions into the master branch,
you could create a trunk branch by doing something like:
COMMIT=$( git show -s --pretty=%b master^^ | \
          git commit-tree master^^:trunk )
COMMIT=$( git show -s --pretty=%b master^ | \
          git commit-tree master^:trunk -p $COMMIT )
COMMIT=$( git show -s --pretty=%b master | \
          git commit-tree master:trunk -p $COMMIT )
echo $COMMIT > .git/refs/heads/foo

The point I was making in IRC was that (so far as I understand) fast-import doesn't let you pass trees around in this way, but instead requires you to transmit the contents of all the changed files.

The code above could of course be achieved more easily with
git-filter-branch, or achieved more efficiently with a custom bit of C.
 I suggested discussing the problem in terms of single-purpose commands
because it strikes me as about the right level to expose the
architectural questions without getting bogged down in detail.
	- Andrew
Previous: Jonathan NiederNext: Jonathan Nieder
Message 17 of 46 in “GSoC intro”
  1. Florian AchleitnerMar 19, 2012
  2. Andrew SayersMar 19, 2012
  3. Florian AchleitnerMar 20, 2012
  4. David BarrMar 20, 2012
  5. Florian AchleitnerMar 21, 2012
  6. Ramkumar RamachandraMar 26, 2012
  7. Florian AchleitnerMar 27, 2012
  8. GSOC Proposal draft: git-remote-svnFlorian Achleitner, Apr 2, 2012
  9. Ramkumar RamachandraApr 2, 2012
  10. Jonathan NiederApr 2, 2012
  11. Jonathan NiederApr 2, 2012
  12. Florian AchleitnerApr 3, 2012
  13. Jonathan NiederApr 3, 2012
  14. Tomas CarneckyApr 5, 2012
  15. Andrew SayersApr 2, 2012
  16. Jonathan NiederApr 2, 2012
  17. Andrew SayersApr 2, 2012
  18. Jonathan NiederApr 3, 2012
  19. Andrew SayersApr 3, 2012
  20. Jonathan NiederApr 3, 2012
  21. Florian AchleitnerApr 5, 2012
  22. Dmitry IvankovApr 5, 2012
  23. Stephen BashApr 9, 2012
  24. Jonathan NiederApr 10, 2012
  25. Andrew SayersApr 10, 2012
  26. Jonathan NiederApr 10, 2012
  27. Florian AchleitnerApr 11, 2012
  28. Andrew SayersApr 14, 2012
  29. Jakub NarebskiApr 11, 2012
  30. Jonathan NiederApr 11, 2012
  31. Florian AchleitnerApr 11, 2012
  32. Dmitry IvankovApr 11, 2012
  33. Jonathan NiederApr 11, 2012
  34. Andrew SayersApr 11, 2012
  35. Thomas RastApr 12, 2012
  36. Florian AchleitnerApr 12, 2012
  37. Andrew SayersApr 12, 2012
  38. Florian AchleitnerApr 14, 2012
  39. Andrew SayersApr 14, 2012
  40. Stephen BashApr 15, 2012
  41. Jonathan NiederApr 13, 2012
  42. Florian AchleitnerApr 14, 2012
  43. Florian AchleitnerApr 18, 2012
  44. Florian AchleitnerApr 19, 2012
  45. Miles BaderMar 28, 2012
  46. Dmitry IvankovMar 28, 2012

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.