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

RE: git-svn set-tree bug

From
JTJoakim Tjernlund <joakim.tjernlund@transmode.se>
Date
Jun 10, 2007, 23:55 UTC
Message-ID
<003401c7abba$c7574300$0e67a8c0@Jocke>
In-Reply-To
<466C8B35.3020207@midwinter.com>
Show 38 quoted lines
> -----Original Message-----
> From: Steven Grimm [mailto:koreth@midwinter.com] 
> Sent: den 11 juni 2007 01:37
> To: Joakim Tjernlund
> Cc: 'Eric Wong'; 'git'
> Subject: Re: git-svn set-tree bug
> 
> Joakim Tjernlund wrote:
> > Is there a way to tell set-tree to commit the whole "merge" branch
> > as one svn commit?
> > If I merge the latest kernel into my tree there will
> > be a lot of commits that I don't want in svn.
> >   
> 
> You want a "squash" merge. Something like this:
> 
> git checkout -b tempbranch origin/svn-branch-to-commit-merge-to
> git merge --squash branch-with-commits-you-want-to-merge
> git commit
> git svn dcommit
> 
> The "merge" command will merge in the changes but will not commit 
> anything; when you do the explicit "commit" command 
> afterwards, you get 
> the contents of the merge but from git's point of view it's just a 
> regular commit so git-svn doesn't get confused.
> 
> After you do git svn dcommit, you may want to edit 
> .git/info/grafts to 
> tell git after the fact that this commit was a merge. It won't hurt 
> git-svn at that point and it will mean you can do another merge later 
> without git getting confused about what has already been merged.
> 
> Take a look at the script I posted a while back, which does something 
> similar:
> 
> http://www.spinics.net/lists/git/msg29119.html
> 
Hi Steven

That looks promising, especially Junos comment about making git-svn able to deal with merges. Eric, do you feel this is doable?

 Jocke 
Previous: Steven GrimmNext: Eric Wong
Message 8 of 27 in “git-svn set-tree bug”
  1. Joakim TjernlundJun 8, 2007
  2. Eric WongJun 10, 2007
  3. Joakim TjernlundJun 10, 2007
  4. Joakim TjernlundJun 10, 2007
  5. Eric WongJun 10, 2007
  6. Joakim TjernlundJun 10, 2007
  7. Steven GrimmJun 10, 2007
  8. Joakim TjernlundJun 10, 2007
  9. Eric WongJun 11, 2007
  10. Junio C HamanoJun 11, 2007
  11. Eric WongJun 12, 2007
  12. Junio C HamanoJun 12, 2007
  13. Eric WongJun 12, 2007
  14. Joakim TjernlundJun 12, 2007
  15. Steven GrimmJun 12, 2007
  16. git-svn: allow dcommit to retain local merge informationEric Wong, Jun 13, 2007
  17. Joakim TjernlundJun 13, 2007
  18. Joakim TjernlundJun 13, 2007
  19. Eric WongJun 20, 2007
  20. Eric WongJun 20, 2007
  21. Joakim TjernlundJun 21, 2007
  22. Joakim TjernlundJul 1, 2007
  23. Steven GrimmJun 14, 2007
  24. Joakim TjernlundJun 22, 2007
  25. Lars HjemliJun 12, 2007
  26. Steven GrimmJun 11, 2007
  27. Joakim TjernlundJun 11, 2007

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.