Mercurial > hg-stable
changeset 3955:497c69726a04
Fix removed file cornercase for CVS convert-repo
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Fri, 22 Dec 2006 17:59:37 -0600 |
parents | 9af4b853ed4d |
children | 558f52943cd2 |
files | mercurial/localrepo.py |
diffstat | 1 files changed, 6 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/localrepo.py Fri Dec 22 17:59:34 2006 -0600 +++ b/mercurial/localrepo.py Fri Dec 22 17:59:37 2006 -0600 @@ -727,11 +727,13 @@ # update manifest m1.update(new) remove.sort() + removed = [] for f in remove: if f in m1: del m1[f] - mn = self.manifest.add(m1, tr, linkrev, c1[0], c2[0], (new, remove)) + removed.append(f) + mn = self.manifest.add(m1, tr, linkrev, c1[0], c2[0], (new, removed)) # add changeset new = new.keys() @@ -747,7 +749,7 @@ if p2 != nullid: edittext.append("HG: branch merge") edittext.extend(["HG: changed %s" % f for f in changed]) - edittext.extend(["HG: removed %s" % f for f in remove]) + edittext.extend(["HG: removed %s" % f for f in removed]) if not changed and not remove: edittext.append("HG: no files changed") edittext.append("") @@ -765,7 +767,7 @@ text = '\n'.join(lines) if branchname: extra["branch"] = branchname - n = self.changelog.add(mn, changed + remove, text, tr, p1, p2, + n = self.changelog.add(mn, changed + removed, text, tr, p1, p2, user, date, extra) self.hook('pretxncommit', throw=True, node=hex(n), parent1=xp1, parent2=xp2) @@ -775,7 +777,7 @@ self.dirstate.setparents(n) if use_dirstate: self.dirstate.update(new, "n") - self.dirstate.forget(remove) + self.dirstate.forget(removed) self.hook("commit", node=hex(n), parent1=xp1, parent2=xp2) return n