Re: problems applying patches created by tortoiseSVN in linux
On 11/14/05, Stefan Küng <firstname.lastname@example.org> wrote:
> Demian Turner wrote:
> > Hi Stefan
> >> "patches created on windows but not with Tortoise have
> >> EOLs automatically dealt with in the patch program".
> >> So I'd like to know if he used e.g. "patch.exe" to create those
> >> patches that worked, or 'svn diff > patchfile'.
> > I'm afraid I don't create the patches, I just apply them, ie projects devs send
> > stuff into SF and our Trac site on a regular basis and after a while the pattern
> > emerged that patches created with tortoiseSVN never work.
> > So it's an empirical observation, sorry I can't offer more detail than that. I
> > can almost guarantee however that the patches were created with patch.exe which
> > must be what's invoked when you use the Tortoise GUI. "svn diff > patchfile"
> > patches created on linux has never caused a problem.
> TortoiseSVN uses the API equivalent of 'svn diff > patchfile', to be
> precise it uses the svn_client_diff() API. So it's highly unlikely that
> only TSVN patches fail to apply but also patches created with the
> command line client svn.exe.
> I think you're problem is with you're use of the patch program (I assume
> you don't use TMerge to apply the patches but 'patch' on your linux
> * Subversion diffs (patches) are in unified diff format, not the default
> patch format.
> * Subversion diffs contain the same lineendings as the files on the
> local system. That means CRLF on windows, LF on linux.
> So you have to pass the correct params to your patch program:
> --unified (or -u)
It is a known bug that if patches contain lines with svn keywords in them
the patches generated won't apply with patch. Issue #2164, but that
should not be every patch, though it may explain a number of them.
To unsubscribe, e-mail: email@example.com
For additional commands, e-mail: firstname.lastname@example.org
Received on Tue Nov 15 04:25:32 2005
This is an archived mail posted to the TortoiseSVN Dev