Mercurial > hgsubversion
changeset 118:a0401f6e14dd
fetch_command: ignore stray files in branches/ in non-diff mode
author | Patrick Mezard <pmezard@gmail.com> |
---|---|
date | Sat, 29 Nov 2008 11:25:01 -0600 |
parents | 3afe404042a3 |
children | ea65fe2b0856 |
files | fetch_command.py tests/fixtures/unrelatedbranch.sh tests/fixtures/unrelatedbranch.svndump |
diffstat | 3 files changed, 41 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/fetch_command.py +++ b/fetch_command.py @@ -424,7 +424,7 @@ def stupid_fetch_branchrev(svn, hg_edito callable to retrieve individual file information. """ kind = svn.checkpath(branchpath, r.revnum) - if kind is None: + if kind != 'd': # Branch does not exist at this revision. Get parent revision and # remove everything. files = parentctx.manifest().keys()
--- a/tests/fixtures/unrelatedbranch.sh +++ b/tests/fixtures/unrelatedbranch.sh @@ -33,6 +33,10 @@ svn cp ../trunk branch2 echo b > branch2/b svn add branch2/b svn ci -m "add b to branch2" +# Add a file in the branch root for fun +echo c > c +svn add c +svn ci -m "add c in branches/" cd ../.. svnadmin dump testrepo > ../unrelatedbranch.svndump
--- a/tests/fixtures/unrelatedbranch.svndump +++ b/tests/fixtures/unrelatedbranch.svndump @@ -1,6 +1,6 @@ SVN-fs-dump-format-version: 2 -UUID: c79f8bc0-a944-4a5d-aaa5-0ce23b313891 +UUID: ec581cb1-163d-4e59-b0b6-af7afd6f1624 Revision-number: 0 Prop-content-length: 56 @@ -9,7 +9,7 @@ Content-length: 56 K 8 svn:date V 27 -2008-11-23T18:54:03.376021Z +2008-11-25T22:20:33.360252Z PROPS-END Revision-number: 1 @@ -27,7 +27,7 @@ pmezard K 8 svn:date V 27 -2008-11-23T18:54:03.444309Z +2008-11-25T22:20:33.498908Z PROPS-END Node-path: branches @@ -63,7 +63,7 @@ pmezard K 8 svn:date V 27 -2008-11-23T18:54:04.175530Z +2008-11-25T22:20:34.165016Z PROPS-END Node-path: trunk/a @@ -93,7 +93,7 @@ pmezard K 8 svn:date V 27 -2008-11-23T18:54:05.192583Z +2008-11-25T22:20:35.178215Z PROPS-END Node-path: branches/branch1 @@ -132,7 +132,7 @@ pmezard K 8 svn:date V 27 -2008-11-23T18:54:07.185050Z +2008-11-25T22:20:37.174989Z PROPS-END Node-path: branches/branch2 @@ -170,3 +170,33 @@ PROPS-END b +Revision-number: 5 +Prop-content-length: 120 +Content-length: 120 + +K 7 +svn:log +V 18 +add c in branches/ +K 10 +svn:author +V 7 +pmezard +K 8 +svn:date +V 27 +2008-11-25T22:20:38.167521Z +PROPS-END + +Node-path: branches/c +Node-kind: file +Node-action: add +Prop-content-length: 10 +Text-content-length: 2 +Text-content-md5: 2cd6ee2c70b0bde53fbe6cac3c8b8bb1 +Content-length: 12 + +PROPS-END +c + +