Mercurial > hgsubversion
diff hgsubversion/svnmeta.py @ 888:c6388ed0ec0a
svnmeta: only remove directory components in normalize()
Previously, a file beginning with the repository subdirectory would be
stripped, resulting in a leftover file name with a wrong name. A
subsequent pull of a revision modifying the file would add it under
its correct name, but leave the leftover file.
author | Dan Villiom Podlaski Christiansen <dan@cabo.dk> |
---|---|
date | Wed, 14 Dec 2011 00:07:57 +0100 |
parents | 6cee57ad9045 |
children | a80b01ceb1fc |
line wrap: on
line diff
--- a/hgsubversion/svnmeta.py +++ b/hgsubversion/svnmeta.py @@ -292,7 +292,9 @@ class SVNMeta(object): return '' if path and path[0] == '/': path = path[1:] - if path and path.startswith(self.subdir): + if path == self.subdir: + return '' + if path and path.startswith(self.subdir + '/'): path = path[len(self.subdir):] if path and path[0] == '/': path = path[1:]