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

Re: [FEATURE REQUEST] git-svn format-patch

From
JHJan Hudec <bulb@ucw.cz>
Date
Mar 11, 2008, 19:22 UTC
Message-ID
<20080311192218.GA7040@efreet.light.src>
In-Reply-To
<320075ff0803111038x36bc40bbkf4b9eec6dd9284fd@mail.gmail.com>
On Tue, Mar 11, 2008 at 17:38:22 +0000, Nigel Magnay wrote:
> Did there ever become a way of generating svn format diffs from git?

There was a talk about it, but I am not sure anything was actually written. Would be quite easy to add the Index: and equals line with a few lines of perl.

> A project is having a hard time applying my format-patch --no-prefix
> diffs, but I don't have a tortoiseSVN machine to figure out why..
You quoted quite precise explanation below.
Show 49 quoted lines
> On Wed, Jan 16, 2008 at 2:20 AM, Daniel Barkalow <barkalow@iabervon.org> wrote:
> > On Tue, 15 Jan 2008, Chris Ortman wrote:
> >
> >
> > > You are correct about Tortoise in that it is too strict.
> >  > I looked through their code and they have written their own patch
> >  > program which keys off these Index: lines
> >  > http://tortoisesvn.tigris.org/svn/tortoisesvn/trunk/src/TortoiseMerge/Patch.cpp
> >  >
> >  > I think it could go either way as to if git-svn creates a different
> >  > format patch or tsvn accepts multiple formats, but I anticipated
> >  > git-svn would be easier to extend so I started here.
> >
> >  I think it would be worthwhile for tsvn to be less picky in some ways. It
> >  should at least be able to accept GNU diff, since sometimes people send
> >  maintainers patches prepared by hand (diff -u file.c.orig file.c), and
> >  there are comments in there that suggest that they're trying to support
> >  non-svn-generated diffs, although they seem to think that such diffs look
> >  like:
> >
> >  Index: filename
> >  ============
> >  @@ -xxx,xxx +xxx,xxx @@
> >  ...
> >
> >  which isn't anything I've ever seen. You're much more likely to get:
> >
> >  ...junk...
> >  --- junk
> >  +++ filename    junk
> >  @@ -xxx,xxx +xxx,xxx @@
> >
> >  And that should be easy enough to parse as an alternative format in tsvn.
> >  (I'd send them a patch to do it, but they wouldn't be able to apply it...)
> >
> >
> >         -Daniel
> >  *This .sig left intentionally blank*
> >  -
> >
> >
> > To unsubscribe from this list: send the line "unsubscribe git" in
> >  the body of a message to majordomo@vger.kernel.org
> >  More majordomo info at  http://vger.kernel.org/majordomo-info.html
> >
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
-- 
						 Jan 'Bulb' Hudec <bulb@ucw.cz>
Previous: Nigel MagnayNext: Daniel Barkalow
Message 52 of 53 in “[FEATURE REQUEST] git-svn format-patch”
  1. Chris OrtmanJan 15, 2008
  2. Johannes SchindelinJan 15, 2008
  3. Chris OrtmanJan 15, 2008
  4. Johannes SchindelinJan 15, 2008
  5. Chris OrtmanJan 15, 2008
  6. Johannes SchindelinJan 15, 2008
  7. Chris OrtmanJan 15, 2008
  8. Johannes SchindelinJan 15, 2008
  9. Chris OrtmanJan 15, 2008
  10. Jan HudecJan 15, 2008
  11. Miles BaderJan 16, 2008
  12. Shawn O. PearceJan 16, 2008
  13. Pascal ObryJan 15, 2008
  14. Daniel BarkalowJan 15, 2008
  15. Junio C HamanoJan 16, 2008
  16. Do not show "diff --git" metainfo with --no-prefixJunio C Hamano, Jan 16, 2008
  17. Johannes SchindelinJan 16, 2008
  18. Junio C HamanoJan 16, 2008
  19. Johannes SchindelinJan 16, 2008
  20. Daniel BarkalowJan 16, 2008
  21. Junio C HamanoJan 16, 2008
  22. Do not show "diff --git" metainfo with --no-prefixJunio C Hamano, Jan 16, 2008
  23. Linus TorvaldsJan 16, 2008
  24. Linus TorvaldsJan 16, 2008
  25. Daniel BarkalowJan 16, 2008
  26. Linus TorvaldsJan 16, 2008
  27. Junio C HamanoJan 16, 2008
  28. Daniel BarkalowJan 16, 2008
  29. Junio C HamanoJan 17, 2008
  30. Johannes SchindelinJan 17, 2008
  31. Junio C HamanoJan 17, 2008
  32. Johannes SchindelinJan 17, 2008
  33. Junio C HamanoJan 17, 2008
  34. Junio C HamanoJan 17, 2008
  35. Johannes SchindelinJan 17, 2008
  36. Junio C HamanoJan 17, 2008
  37. Johannes SchindelinJan 17, 2008
  38. Jeff KingJan 17, 2008
  39. Jeff KingJan 17, 2008
  40. Johannes SchindelinJan 17, 2008
  41. Jeff KingJan 17, 2008
  42. Junio C HamanoJan 18, 2008
  43. Junio C HamanoJan 16, 2008
  44. Daniel BarkalowJan 16, 2008
  45. Jan HudecJan 19, 2008
  46. Junio C HamanoJan 16, 2008
  47. Chris OrtmanJan 16, 2008
  48. Jean-Luc HerrenJan 15, 2008
  49. Chris OrtmanJan 15, 2008
  50. Daniel BarkalowJan 16, 2008
  51. Nigel MagnayMar 11, 2008
  52. Jan HudecMar 11, 2008
  53. Daniel BarkalowMar 12, 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.