# HG changeset patch # User Alexis S. L. Carvalho # Date 1164058357 7200 # Node ID 3a2fc90d27d6c7eccae6c368cdb7c97088231b24 # Parent c0b1a0c72c7d1032b281507e47e049a712c23a5b fix typo in mercurial/patch.py diff -r c0b1a0c72c7d -r 3a2fc90d27d6 mercurial/patch.py --- a/mercurial/patch.py Mon Nov 20 19:32:36 2006 -0200 +++ b/mercurial/patch.py Mon Nov 20 19:32:37 2006 -0200 @@ -516,7 +516,7 @@ src = repo.dirstate.copied(f) parent = repo.dirstate.parents()[0] if src: - f = src[0] + f = src of = renamedbetween(f, node1, parent) if of: return of diff -r c0b1a0c72c7d -r 3a2fc90d27d6 tests/test-git-export --- a/tests/test-git-export Mon Nov 20 19:32:36 2006 -0200 +++ b/tests/test-git-export Mon Nov 20 19:32:37 2006 -0200 @@ -94,3 +94,21 @@ echo '% file created after r1 and renamed before r2' hg diff --git -r -5:-1 +echo +echo '% comparing with the working dir' +echo >> start +hg ci -m 'change start again' -d '0 0' + +echo > created +hg add created +hg ci -m 'add created' + +hg mv created created2 +hg ci -m 'mv created created2' + +hg mv created2 created3 +echo "% there's a copy in the working dir..." +hg diff --git +echo +echo "% ...but there's another copy between the original rev and the wd" +hg diff --git -r -2 diff -r c0b1a0c72c7d -r 3a2fc90d27d6 tests/test-git-export.out --- a/tests/test-git-export.out Mon Nov 20 19:32:36 2006 -0200 +++ b/tests/test-git-export.out Mon Nov 20 19:32:37 2006 -0200 @@ -102,3 +102,14 @@ +a +b +c + +% comparing with the working dir +% there's a copy in the working dir... +diff --git a/created2 b/created3 +rename from created2 +rename to created3 + +% ...but there's another copy between the original rev and the wd +diff --git a/created b/created3 +rename from created +rename to created3