[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: tortoise svn 1.7.3 bug: applying patches fail if there is a new directory in the patch

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: Fri, 23 Dec 2011 22:55:38 +0100

On 23.12.2011 19:11, Chris Duncan wrote:
> Ok, I've sent an email to users_at_tortoisesvn.tigris.org
> If that is wrong, or I need to subscribe first, let me know please.
> Email content is below:
>
>
>
> I have 1-3 bugs to report,
>
> 1st:
> Updating_PBEM_system.patch
> I have a patch where someone added a file to a new directory. The patch file works when I apply it using Tortoise SVN 1.6.x, however it fails with Tortoise 1.7.3
> By that i mean it fails completely, and will not let me even apply parts of the patch. It just exists after the error message. (doing right click -> apply patch)
>
> The message is:
> "The Node
> blah../../newDirectory
> was not found"
>
> example:
> My current workspace has blah1/
> And someone made a patch that adds this file to blah1/blah2/file.txt
>
> This is bug #1.
> When I tried to apply this patch using Tortoise SVN 1.6.x on a different computer, the patch worked for all the files it was modifying except for 1 file, which was done incorrectly. I guess this one incorrect file could be causing the error above, but it should be noted that the 1 file that was done incorrectly in the patch file was NOT one of the files that was in a new directory. The badly done file was an already existing file.
> (Index: src/games/puzzle/tictactoe/TicTacToe.java was the single 'file' inside of the patch that did not work)

I've opened issue #174 for this:
http://code.google.com/p/tortoisesvn/issues/detail?id=174

> 2nd:
> Updating_PBEM_system.patch
> So, using the other computer running tortoise svn 1.6.x, I applied the patch file to my workspace. I applied all changes except the one to TicTacToe.java, and then I did the changes to TicTacToe manually based on looking at the patch file.
>
> I noticed that applying the patch did not change the names of some files,
> example:
> Index: src/games/strategy/triplea/pbem/AxisAndAlliesDotOrgPBEMMessenger.java
> ===================================================================
> --- src/games/strategy/triplea/pbem/AxisAndAlliesDotOrgPBEMMessenger.java (revision 3313)
> +++ src/games/strategy/triplea/pbem/AxisAndAlliesForumPoster.java (revision )
>
> According to what i know, it should change the name of the file. Anyway, I had to do it manually. This is bug #2.

patching in TSVN 1.7 is done with the svn library patch function. That
function does not support renames (yet).
You can ask on their mailing list if/when that gets implemented (users
at subversion.apache.org)

> 3rd:
> Updating_PBEM_system_V2.patch
> After this, I created a new patch file on my Tortoise SVN 1.6.x machine (tortoise svn 1.6, right click -> create patch file), that way I could send it back to my colleague.
> I decided to see if this patch file would work on my Tortoise SVN 1.7.3 machine, so I tried that.
> Amazingly it sort-of worked.
> However, it showed 11 of the 'files' in the patch to be Red. When I clicked on any of these, the message was "Rejected patch hunk for ......"
> The rejected 11 were all the ones in the new directory.
> This is bug #3.

That works fine with my latest build from trunk.
Maybe this is already fixed on the svn 1.7.x branch?

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.net
------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=4061&dsMessageId=2899466
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_tortoisesvn.tigris.org].
Received on 2011-12-23 22:55:48 CET

This is an archived mail posted to the TortoiseSVN Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.